summaryrefslogtreecommitdiffstats
path: root/frontend/src/Home.js
diff options
context:
space:
mode:
Diffstat (limited to 'frontend/src/Home.js')
-rw-r--r--frontend/src/Home.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/frontend/src/Home.js b/frontend/src/Home.js
index bf98bf1..cc37156 100644
--- a/frontend/src/Home.js
+++ b/frontend/src/Home.js
@@ -5,6 +5,12 @@ import LogoutBtn from './LogoutBtn';
import userState from './UserState';
const Home = observer(({ user }) => {
+ if (user.authError) {
+ const err = user.authError;
+ const text = (err.response && err.response.data.message) || String(err);
+ return <div className="error">{text}</div>;
+ }
+
if (!user.username) {
return 'Loading...';
}