mirror of
https://github.com/opensupports/opensupports.git
synced 2025-07-28 08:14:25 +02:00
Revert "Fix #125 Maintenance mode"
This reverts commit 0837754ffb1219c575bca9dbad3b80c640afa614.
This commit is contained in:
parent
2d83116520
commit
a68aa76b2f
2
.gitignore
vendored
2
.gitignore
vendored
@ -2,5 +2,3 @@ server/composer.lock
|
|||||||
server/vendor
|
server/vendor
|
||||||
.idea
|
.idea
|
||||||
.jshintrc
|
.jshintrc
|
||||||
server/files/
|
|
||||||
!server/files/.gitkeep
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
|
|
||||||
'serverport': 3006,
|
'serverport': 3000,
|
||||||
|
|
||||||
'scripts': {
|
'scripts': {
|
||||||
'src': './src/*.js',
|
'src': './src/*.js',
|
||||||
|
@ -65,11 +65,11 @@ class App extends React.Component {
|
|||||||
loggedOutStaff: _.includes(props.location.pathname, '/admin/panel') && !props.session.logged
|
loggedOutStaff: _.includes(props.location.pathname, '/admin/panel') && !props.session.logged
|
||||||
};
|
};
|
||||||
|
|
||||||
if(props.config['maintenance-mode'] && !_.includes(props.location.pathname, '/admin') && !_.includes(props.location.pathname, '/maintenance')) {
|
if(props.config['maintenance-mode'] === '1' && !_.includes(props.location.pathname, '/admin') && !_.includes(props.location.pathname, '/maintenance')) {
|
||||||
history.push('/maintenance');
|
history.push('/maintenance');
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!props.config['maintenance-mode'] && _.includes(props.location.pathname, '/maintenance')) {
|
if(props.config['maintenance-mode'] === '0' && _.includes(props.location.pathname, '/maintenance')) {
|
||||||
history.push('/');
|
history.push('/');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -60,7 +60,6 @@ class SessionStore {
|
|||||||
this.setItem('registration', configs.registration);
|
this.setItem('registration', configs.registration);
|
||||||
this.setItem('user-system-enabled', configs['user-system-enabled']);
|
this.setItem('user-system-enabled', configs['user-system-enabled']);
|
||||||
this.setItem('allow-attachments', configs['allow-attachments']);
|
this.setItem('allow-attachments', configs['allow-attachments']);
|
||||||
this.setItem('maintenance-mode', configs['maintenance-mode']);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
getConfigs() {
|
getConfigs() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user