Fix issue when map is shared for view

This commit is contained in:
Paulo Gustavo Veiga 2022-03-09 10:54:48 -08:00
parent cc0de5e03c
commit 2d1d0a8790

View File

@ -38,7 +38,7 @@ const EditorPage = ({ isTryMode }: EditorPropsType): React.ReactElement => {
if (fetchResult.error) {
throw new Error(`Map information could not be loaded: ${JSON.stringify(fetchResult)}`);
}
result = fetchResult?.map?.role === 'owner' ? 'edition-owner' : 'edition-editor';
result = `edition-${fetchResult?.map?.role}`;
}
}
return result;