mirror of
https://github.com/plankanban/planka.git
synced 2025-07-18 20:59:44 +02:00
feat: Use environment variables for default admin configuration
This commit is contained in:
parent
2dfa79801f
commit
e59535b9b4
20 changed files with 224 additions and 121 deletions
|
@ -67,6 +67,13 @@ module.exports = {
|
|||
throw Errors.USER_NOT_FOUND;
|
||||
}
|
||||
|
||||
if (user.email === sails.config.custom.defaultAdminEmail) {
|
||||
/* eslint-disable no-param-reassign */
|
||||
delete inputs.isAdmin;
|
||||
delete inputs.name;
|
||||
/* eslint-enable no-param-reassign */
|
||||
}
|
||||
|
||||
const values = {
|
||||
..._.pick(inputs, [
|
||||
'isAdmin',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue