ibm-bluemix-mobile-services/bms-clientsdk-cordova-plugin-push

Thread 9: Fatal error: Unexpectedly found nil while unwrapping an Optional value

Closed this issue · 5 comments

Building app with latest xcode 10.2.1, calling bmspush registerDevice the app hangs and throws this error: Thread 9: Fatal error: Unexpectedly found nil while unwrapping an Optional value.

Below screenshot of the exact line and error.

Screenshot 2019-05-28 at 15 37 47

@gitsaysno Hi, That's a config issue I think . Did you add the appgUID, ClientSecret and region in push plugin init method. Please refer this - https://github.com/ibm-bluemix-mobile-services/bms-clientsdk-cordova-plugin-push#register-for-push-notifications

Yea, its added but now i noticed that xcode logs the following error msg when initialising:

2019-05-29 09:21:56.025918+0200 Plus Connect Pro[319:11321] ERROR: Method 'initialize:' not defined in Plugin 'BMSClient'

2019-05-29 09:21:56.026054+0200 Plus Connect Pro[319:11321] FAILED pluginJSON = ["BMSClient477522305","BMSClient","initialize",[".eu-de.bluemix.net"]]

Screenshot 2019-05-29 at 09 49 39

I also ran a new clean cordova create project and installed only bms push and i get the same error. (im choosing swift v 4 in the build settings)

@gitsaysno There is an issue with the Core plugin (https://github.com/ibm-bluemix-mobile-services/bms-clientsdk-cordova-plugin-core). I will fix it ASAP and let you know. Thank you for reporting this issue. 👍

@gitsaysno I have released a new version of core plugin. The latest core plugin version is bms-core -> 2.6.0. Update your dependencies, that will fix the above issue. Thanks .

That release solved the issue. Thanks for quick response. 👍