1
0
mirror of https://github.com/oceanprotocol/market.git synced 2024-12-02 05:57:29 +01:00

merge feature/v4 into feature/v4-c2d

This commit is contained in:
Bogdan Fazakas 2022-05-04 15:55:59 +03:00
commit dff4a0ca1c
2 changed files with 7 additions and 3 deletions

View File

@ -105,7 +105,7 @@ export default function FormEditMetadata({
}
{...field}
component={Input}
prefix={field.name === 'price' && oceanConfig.oceanTokenSymbol}
prefix={field.name === 'price' && oceanConfig?.oceanTokenSymbol}
onChange={(e: ChangeEvent<HTMLInputElement>) =>
handleFieldChange(e, field)
}

View File

@ -37,13 +37,17 @@ export default function Edit({ uri }: { uri: string }): ReactElement {
}
].filter((tab) => tab !== undefined)
return asset && asset?.accessDetails && accountId === owner ? (
return asset &&
asset?.accessDetails &&
accountId?.toLowerCase() === owner?.toLowerCase() ? (
<Page title={pageTitle} noPageHeader uri={uri}>
<div className={styles.container}>
<Tabs items={tabs} defaultIndex={0} className={styles.edit} />
</div>
</Page>
) : asset && asset?.accessDetails && accountId !== owner ? (
) : asset &&
asset?.accessDetails &&
accountId?.toLowerCase() !== owner?.toLowerCase() ? (
<Page title={pageTitle} noPageHeader uri={uri}>
<Alert
title="Edit action available only to asset owner"