Skip to content
This repository was archived by the owner on Apr 12, 2023. It is now read-only.

Added Logout Feature - #298

Open
sayyss wants to merge 1 commit into
JBossOutreachArchive:masterfrom
sayyss:logout
Open

Added Logout Feature#298
sayyss wants to merge 1 commit into
JBossOutreachArchive:masterfrom
sayyss:logout

Conversation

@sayyss

@sayyss sayyss commented Dec 20, 2019

Copy link
Copy Markdown

Check by changing each [ ] to [x] Please take note of the white-space as it matters.

  • This Pull request
    • Fixes a bug.
    • Implements a new feature.
  • I have read the [CONTRIBUTING.md] .
  • I have included a description of changes below.
  • I have included screenshots showing before and after the changes were made.
  • I have squashed the commits (mandatory).

Description / Changes

Added Logout Feature

Screenshots

Youtube - Link

@anshumanv anshumanv left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your work! You didn't have to open a new PR, you can amend the old PR by adding subsequent commits. LGTM

constructor(private router: Router) { }

// Check if User is Logged In
isLoggedin(){

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi! Thanks for going with the suggested approach, you can further simplify this in future like

isLoggedIn() {
  return localStorage.getItem('token') !== null
}

But this works totally fine.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants