Fakultas Ilmu Komputer UI

Commit a8a8ac45 authored by Zafir Rasyidi Taufik's avatar Zafir Rasyidi Taufik
Browse files

[CHORES]Fix undefined response error if token is already set on startup

parent 02635f38
......@@ -177,7 +177,7 @@ const App = () => {
if (token) {
const getUser = async () => {
const response = await mainService.me()
if (response.status === 200) {
if (response?.status === 200) {
// Token is valid
setUser(response.data)
navigatorRef.current?.reset({
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment