Test, whether a user is logged in

We need to use the loginviapost-plugin which works very well.
Now we want to hide our own login-page, if a user logged in via the loginviapost-plugin.
Is there an possibility to check, if a user / session has logged-in / started through this plugin?

I can create a session when the user logs in, but if he logs out fron nextcloud, this session wont be destroyed.