fix(core): deprecation notices thrown at login/logout even if there's no...

... valid reason

Stops the wrongly thrown deprecated notices at login/logout for supposed deprecated usage of ['login', 'user'] and ['logout', 'user'] events even if there are no handlers registered for these deprecated events as mentioned in #6493.
The variable naming could be better, but it works and I want to close out all 1.9 PRs.