Skip to content

Commit

Permalink
fix: added specific pathname in upload file restriction
Browse files Browse the repository at this point in the history
  • Loading branch information
sabrina-bongiovanni committed Jan 13, 2025
1 parent c1ffe5a commit 74d50bb
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ class ContentsUploadModal extends Component {
// this is enough to identify this only case bc even if another page is called 'modulistica', it will have 'File'
// and "Modulo" as addable type
const showFileRestraint =
this.props.pathname.includes('modulistica') &&
getBaseUrl(this.props.pathname).match(/\/servizi\/.*\/modulistica\/?$/) &&
!this.props.types.some(
(type) => type.id === 'File' || type.id === 'Modulo',
);
Expand Down

0 comments on commit 74d50bb

Please sign in to comment.