4

I am developing a MonoGame app for Windows Phone 8. I am using the .Net SDK of Parse for my backend services. I login the user using

ParseUser user = await ParseFacebookUtils.LogInAsync(browser, null);

This redirects the app to the web browser for login and automatically returns back into the app after login is finished or cancelled. At this point I can call ParseUser.CurrentUser to get the current logged in Facebook user (null if not logged in). According to Parse's docs:

It would be bothersome if the user had to log in every time they open your app. You can avoid this by using the cached ParseUser.CurrentUser object.

Whenever you use any signup or login methods, the user is cached on disk. You can treat this cache as a session, and automatically assume the user is logged in

So after I login, I restart the app expecting ParseUser.CurrentUser to return the previously logged in user, but it doesn't, instead returning null, so I have to login again. I cant tell if am doing something wrong or if it is a bug.

user123
  • 632
  • 1
  • 6
  • 22

1 Answers1

0

Are you using/enabling the local datastore in Parse?

If yes, your issue might relate to this: https://www.parse.com/questions/android-local-datastore-getcurrentuser

Zsolt Safrany
  • 13,290
  • 6
  • 50
  • 62
  • No I was not aware of enabling the local datastore bit. Either way I have long abandoned Parse for Facebook and implemented my own login flow, so currently I cant confirm if the info in your link actually fixes the issue... I might recheck in the future. – user123 Jun 22 '14 at 13:43