nicolium: fix avatar/header getting removed

Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
This commit is contained in:
nicole mikołajczyk
2026-03-17 11:39:48 +01:00
parent 6db8ac8a24
commit 70db9d5798

View File

@ -332,8 +332,8 @@ const EditProfilePage: React.FC = () => {
params.fields_attributes = Object.fromEntries(
fields_attributes.map(({ name, value }, i) => [i.toString(), { name, value }]),
);
if (header.file !== undefined) params.header = header.file ?? '';
if (avatar.file !== undefined) params.avatar = avatar.file ?? '';
if (header.file !== null) params.header = header.file ?? '';
if (avatar.file !== null) params.avatar = avatar.file ?? '';
if (!instance.configuration.accounts?.allow_custom_css) delete params.custom_css;