Skip to content

Commit

Permalink
Merge branch 'staging' into deployments/arbitrum
Browse files Browse the repository at this point in the history
  • Loading branch information
froid1911 committed Apr 24, 2024
2 parents 6f1a995 + ef3cbc6 commit c7c5c97
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions src/hooks/useIsAllowedToCreateDocuments.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,15 @@ export function useIsAllowedToCreateDocuments() {
const createDocumentAllowListEnvString = import.meta.env
.VITE_CREATE_DOCUMENT_ALLOW_LIST;

const createDocumentAllowList =
createDocumentAllowListEnvString?.split(',');
if (createDocumentAllowList === undefined) {
if (
createDocumentAllowListEnvString === undefined ||
createDocumentAllowListEnvString === ''
) {
return true;
}

const createDocumentAllowList = createDocumentAllowListEnvString.split(',');
if (createDocumentAllowList.length === 0) {
return true;
}

Expand Down

0 comments on commit c7c5c97

Please sign in to comment.