Skip to content

Commit 6db0467

Browse files
author
vikasrohit
authored
Merge pull request #2379 from appirio-tech/hotfix/bring_back_compile_time_maintenance_mode
Hotfix/bring back compile time maintenance mode
2 parents 25fcd20 + ff20d7e commit 6db0467

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/components/Layout/Layout.jsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React from 'react'
22
import Footer from '../Footer/Footer'
3-
// import { MAINTENANCE_MODE } from '../../config/constants'
3+
import { MAINTENANCE_MODE } from '../../config/constants'
44
import Alert from 'react-s-alert'
55
import cn from 'classnames'
66
import { GatewayDest } from 'react-gateway'
@@ -17,7 +17,7 @@ const Layout = (props) => {
1717

1818
if (isLoadingUser) {
1919
return (<div />)
20-
} else if (maintenanceMode) {
20+
} else if (MAINTENANCE_MODE || maintenanceMode) {
2121
return <Maintenance />
2222
} else {
2323
return (

src/config/constants.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -496,7 +496,7 @@ export const PROJECT_MAX_COLORS = 5
496496
export const AUTOCOMPLETE_TRIGGER_LENGTH = 3
497497

498498
// Toggle this flag to enable/disable maintenance mode
499-
export const MAINTENANCE_MODE = false
499+
export const MAINTENANCE_MODE = process.env[`${process.env.ENV}_MAINTENANCE_MODE`]
500500

501501
export const LS_INCOMPLETE_PROJECT = 'incompleteProject'
502502

0 commit comments

Comments
 (0)