How my app can know when user logout from its native Facebook app ?
I am using below code for Logging out from Facebook in my app. And it is working fine.
Hmmmm... It may be get tricky. I guess the isSessionValid is offline checking from the FB API.
From your situation, it looks like you still need to have a single call to the FB to check the session is really valid or not. So my suggestion based on your situation is to make simple FB API call such as /me
just to check the validity of the session.
If session is valid, then you manually call the logout API, otherwise, you know that the FB session is either expired/logged out.
Hope helps :)