Small fix to Settings modal

We need a PR to fix this
This commit is contained in:
Justin Edmund 2022-12-23 16:17:24 -08:00
parent d5d404abde
commit b1d7802e43

View file

@ -24,18 +24,6 @@ const AccountModal = () => {
const locale = const locale =
router.locale && ['en', 'ja'].includes(router.locale) ? router.locale : 'en' router.locale && ['en', 'ja'].includes(router.locale) ? router.locale : 'en'
// Cookies
const cookie = getCookie('account')
const headers = {}
// cookies.account != null
// ? {
// headers: {
// Authorization: `Bearer ${cookies.account.access_token}`,
// },
// }
// : {}
// State // State
const [open, setOpen] = useState(false) const [open, setOpen] = useState(false)
const [picture, setPicture] = useState('') const [picture, setPicture] = useState('')
@ -171,12 +159,16 @@ const AccountModal = () => {
pictureData.find((i) => i.filename === picture)?.element pictureData.find((i) => i.filename === picture)?.element
}`} }`}
> >
<img {picture ? (
alt="Profile preview" <img
srcSet={`/profile/${picture}.png, alt="Profile preview"
srcSet={`/profile/${picture}.png,
/profile/${picture}@2x.png 2x`} /profile/${picture}@2x.png 2x`}
src={`/profile/${picture}.png`} src={`/profile/${picture}.png`}
/> />
) : (
''
)}
</div> </div>
<select <select