I found the solution putting a setTimeOut in your platform.ready:
sudo ionic cordova plugin add phonegap-plugin-push –variable SENDER_ID=XXXXXX
setTimeout(()=>{
this.initPushNotification();
}, 1000);
1 weeks founding this error…











![Cannot read property ‘toLowerCase’ of undefined [ERROR] An error occurred while running subprocess cordova.](https://blog.rahulbhutani.com/wp-content/uploads/2020/12/ionic-enable-xcode-permissions-banner-218x150.png)






