Skip to content

Commit

Permalink
Fix condition for external routes.
Browse files Browse the repository at this point in the history
  • Loading branch information
GhitaB committed Jun 13, 2023
1 parent e00d393 commit 9d30963
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,13 @@ import GeolocationWidget from './components/theme/Widgets/GeolocationWidget';

const applyConfig = (config) => {
const notInEnMission = /^(?!(\/en\/mission)).*$/;
if (!__DEVELOPMENT__ && !process.env.RAZZLE_DISABLE_EXTERNAL_ROUTES) {
if (
!(
__DEVELOPMENT__ ||
(process.env.RAZZLE_DISABLE_EXTERNAL_ROUTES &&
process.env.RAZZLE_DISABLE_EXTERNAL_ROUTES === 'True')
)
) {
config.settings.externalRoutes = [
...(config.settings.externalRoutes || []),
{
Expand Down

0 comments on commit 9d30963

Please sign in to comment.