Browse Source
Merge pull request #5 from naresh97/development
added scanner logout toast
master
Nareshkumar Rao
3 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
6 additions and
1 deletions
-
src/screens/ScannerScreen.js
|
|
@ -55,7 +55,12 @@ function Scanner() { |
|
|
|
duration: 2000, |
|
|
|
}); |
|
|
|
} else { |
|
|
|
console.log('Time to logout!'); |
|
|
|
toast({ |
|
|
|
title: "You're not logged in!", |
|
|
|
description: "Please log in and try again!", |
|
|
|
status: 'error', |
|
|
|
duration: 2000, |
|
|
|
}); |
|
|
|
dispatch(authLogout()); |
|
|
|
history.push('/login'); |
|
|
|
} |
|
|
|