1
That is the code
public override void OnCreate()
{
try
{
base.OnCreate();
//If debug you should reset the token each time.
#if DEBUG
FirebasePushNotificationManager.Initialize(this, true);
#else
PushNotificationManager.Initialize(this,false);
#endif
//Handle notification when app is closed here
CrossFirebasePushNotification.Current.OnNotificationReceived += (s, p) =>
{
};
//CrossFirebasePushNotification.Current.Subscribe("Managers");
}
catch(Exception ex)
{
string err = ex.Message;
}
}
The mistake comes in this line
FirebasePushNotificationManager.Initialize(this, true);
EDIT1
After giving a clean and adding these lines to my csproj, no more error
<Target Name="RemoveGoogleServicesJsonStampFiles" BeforeTargets="BeforeBuild">
<Delete Files="$(IntermediateOutputPath)\ProcessGoogleServicesJson.stamp" />
</Target>
That seems to have solved.
Which error is triggered? Only Unhandled Exception?
– Artur Trapp
@Arturotemplary, that’s right. I put a Try.. catch, but does not enter the catch, already triggers the exception. If comment works, but does not generate the token in debug
– pnet