Skip to content

Commit

Permalink
fix linting
Browse files Browse the repository at this point in the history
  • Loading branch information
joejknowles committed Jul 29, 2020
1 parent d1dd7d5 commit 7c28a20
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
14 changes: 7 additions & 7 deletions examples/with-firebase-authentication/utils/auth/mapUserData.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
export const mapUserData = user => {
const { uid, email, xa } = user
return {
id: uid,
email,
token: xa,
}
export const mapUserData = (user) => {
const { uid, email, xa } = user
return {
id: uid,
email,
token: xa,
}
}
12 changes: 6 additions & 6 deletions examples/with-firebase-authentication/utils/auth/userCookies.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@ import cookies from 'js-cookie'

export const getUserFromCookie = () => {
const cookie = cookies.get('auth')
if (!cookie) {
return
}
return JSON.parse(cookie)
if (!cookie) {
return
}
return JSON.parse(cookie)
}

export const setUserCookie = user => {
export const setUserCookie = (user) => {
cookies.set('auth', user, {
// firebase id tokens expire in one hour
// set cookie expiry to match
expires: 1/24,
expires: 1 / 24,
})
}

Expand Down

0 comments on commit 7c28a20

Please sign in to comment.