https://github.com/Unity-Technologies/com.unity.mobile.notifications/issues/155
Look like some users use code from sample in production.
The only reason I see for the error happening is when for some reason writes to file were not flushed, so if app got killed and relaunched, it's possible that file was truncated by writer and now is empty, so it passes existence check.
Couple simple changes:
wrap serialization/deserialization code with try-catch for IO exceptions
https://github.com/Unity-Technologies/com.unity.mobile.notifications/issues/155 Look like some users use code from sample in production. The only reason I see for the error happening is when for some reason writes to file were not flushed, so if app got killed and relaunched, it's possible that file was truncated by writer and now is empty, so it passes existence check.
Couple simple changes: