Fix change fields

This commit is contained in:
ilya-bkv 2022-12-03 14:17:19 +03:00
parent 953c12a0c6
commit 7c373697f0
2 changed files with 3 additions and 5 deletions

View File

@ -32,10 +32,9 @@ export const ProfileSettingsPage = (props: PageProps) => {
method: 'POST', method: 'POST',
body: formData body: formData
}) })
console.log('!!! resp:', resp) console.log('!!! resp:', resp)
} catch (e) { } catch (error) {
const resp = e.response console.log('!!! error', error)
} }
}) })
} }
@ -182,7 +181,6 @@ export const ProfileSettingsPage = (props: PageProps) => {
</div> </div>
</div> </div>
</div> </div>
<pre>{JSON.stringify(form, null, 2)}</pre>
</div> </div>
</Show> </Show>
</PageWrap> </PageWrap>

View File

@ -34,7 +34,7 @@ const useProfileForm = () => {
await loadAuthor({ slug: currentSlug() }) await loadAuthor({ slug: currentSlug() })
setForm({ setForm({
name: currentAuthor()?.name, name: currentAuthor()?.name,
slug: currentAuthor()?.name, slug: currentAuthor()?.slug,
bio: currentAuthor()?.bio, bio: currentAuthor()?.bio,
userpic: currentAuthor()?.userpic, userpic: currentAuthor()?.userpic,
links: currentAuthor()?.links links: currentAuthor()?.links