TypeError: Cannot read property 'registerVoipToken' of null

22 Views Asked by At

I have a legacy react-native project. I'm using react-native-voip-push-notification

The issue arises whenever I attempt to invoke VoipPushNotification?.registerVoipToken() in my code, resulting in the error;

"Cannot read property 'registerVoipToken' of null" in node_modules/react-native-voip-push-notification/index.js at line 95 RNVoipPushNotificationManager.registerVoipToken()

node_modules/react-native-voip-push-notification/index.js

    static registerVoipToken() {
        RNVoipPushNotificationManager.registerVoipToken();
    }

Causing the app to crash. I've tried to find a solution but haven't found one yet. Crash occurs only in android

0

There are 0 best solutions below