iOS Capacitor Push Notifications calling the wrong registration callback?

so, in ngOnInit of the welcome-page.component.ts of my angular-ionic app i’m calling this:

if (Capacitor.platform !== "web") { this.registerPush(); }

which is:

`private async registerPush() {
if (Capacitor.getPlatform() === “android”) {
let permStatus = await PushNotifications.checkPermissions();

  if (permStatus.receive === "prompt") {
    permStatus = await PushNotifications.requestPermissions();
  }

  if (permStatus.receive !== "granted") {
    throw new Error("User denied permissions!");
  }

  await PushNotifications.register();
} else if (Capacitor.getPlatform() === "ios") {
  PushNotifications.requestPermissions().then((result) => {
    if (result.receive === "granted") {
      PushNotifications.register();
    } else {
      console.error("User denied push notification permissions!");
    }
  });
}

PushNotifications.addListener("registration", async (token) => {
  console.log("My token: " + token.value);

  const user = await this.authService.getUserInSession();
  const decryptUser = Globals.decryptOjbectsInSession(user);

  this.authService
    .updateRegKey({
      cpf_cnpj: decryptUser.usuario.cpfcnpj,
      reg_key: token.value,
    })
    .subscribe((response: any) => {
      console.log("response: ", response);
    });
});

PushNotifications.addListener("registrationError", (error) => {
  console.log("Error on registration: " + JSON.stringify(error));
});

PushNotifications.addListener(
  "pushNotificationReceived",
  (notification) => {
    console.log("Push notification received: ", notification);
  }
);

PushNotifications.addListener(
  "pushNotificationActionPerformed",
  (notification) => {
    console.log(
      "Push notification action performed",
      notification.actionId,
      notification.inputValue
    );

    this.router.navigate([notification.notification.data.url]);
  }
);
}`

and i believe this is exactly done as in the documentation is said to. and it DOES work on android, both simulator and physical device, it takes the device token and then registers on my postgres db, so that i can use API to send the notification.
enter image description here

BUT, for iOS simulator (i don’t have a physical one to test) it simply doesn’t work.
ios add listeners
ios doesnt call the right callback

and i don’t know how this works exactly, but it looks like it is calling another callback. see, the registration callback that i have created, is apparently the “#11279332” one, and when it’s called, the one that’s called is the “#11279336” one. on Android, they’re the same (#102964981)

i tried following both documentations that i could find:
https://capacitorjs.com/docs/guides/push-notifications-firebase
https://ionicframework.com/docs/native/push-notifications

installed capacitor/push-notifications and used the command “npx cap sync”

created the firebase project, got the GoogleService-Info.plist, added in xCode like it is asked to, and i also added the authkey from apple to the firebase project

added the “pod Firebase/Messaging'” to the Pods file and updated using “npx cap update ios”

also added the “import Firebase” and the “FirebaseApp.configure()” to the AppDelegate.swift, and both functions:

func application(_ application: UIApplication, didRegisterForRemoteNotificationsWithDeviceToken deviceToken: Data) {
Messaging.messaging().apnsToken = deviceToken
Messaging.messaging().token(completion: { (token, error) in
if let error = error {
    NotificationCenter.default.post(name: .capacitorDidFailToRegisterForRemoteNotifications, object: error)
} else if let token = token {
    NotificationCenter.default.post(name: .capacitorDidRegisterForRemoteNotifications, object: token)
}
})
}`

func application(_ application: UIApplication, didFailToRegisterForRemoteNotificationsWithError error: Error) { NotificationCenter.default.post(name: .capacitorDidFailToRegisterForRemoteNotifications, object: error) }

i’ve used the commands: “ionic build” and “npx cap copy”, and then opened the vscode with “npx cap open ios”

i’ve created the apple profile with the push-notifications permission and uploaded it to xcode,
ios profile
enter image description here

i also enabled the push-notifications capability inside vscode.

there are a lot of steps, and i believe i have done them all. can someone tell me what am i doing wrong?

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật