Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

loggedIn and loggedOut fire loggingIn and logginOut events #151

Open
jankapunkt opened this issue Feb 14, 2024 · 1 comment
Open

loggedIn and loggedOut fire loggingIn and logginOut events #151

jankapunkt opened this issue Feb 14, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@jankapunkt
Copy link
Member

jankapunkt commented Feb 14, 2024

Describe the bug

  _startLoggingIn() {
    this._reactiveDict.set('_loggingIn', true);
    Data.notify('loggingIn');
  },
  _startLoggingOut() {
    User._isLoggingOut = true;
    Data.notify('loggingOut');
  },
  _endLoggingIn() {
    this._reactiveDict.set('_loggingIn', false);
    Data.notify('loggingIn');
  },
  _endLoggingOut() {
    User._isLoggingOut = false;
    Data.notify('loggingOut');
  },

it's not determinable, at which method the even has fired as they are clearly the same.

Expected behavior
It should be distinguishable at which function the events fired. Proposed change would be to use clear naming:

  _startLoggingIn() {
    this._reactiveDict.set('_loggingIn', true);
    Data.notify('loggingIn');
  },
  _startLoggingOut() {
    User._isLoggingOut = true;
    Data.notify('loggingOut');
  },
  _endLoggingIn() {
    this._reactiveDict.set('_loggingIn', false);
    Data.notify('loggedIn');
  },
  _endLoggingOut() {
    User._isLoggingOut = false;
    Data.notify('loggedOut')
  },
@jankapunkt jankapunkt added the bug Something isn't working label Feb 14, 2024
Copy link

Closing this issue due to no activity. Feel free to reopen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant