mirror of
https://github.com/plankanban/planka.git
synced 2025-07-20 13:49:43 +02:00
Move from prettier-eslint to eslint-plugin-prettier, update dependencies
This commit is contained in:
parent
f0e7fb8fd1
commit
9c7c96a780
254 changed files with 5539 additions and 5170 deletions
|
@ -10,9 +10,10 @@ module.exports = {
|
|||
},
|
||||
values: {
|
||||
type: 'json',
|
||||
custom: (value) => _.isPlainObject(value)
|
||||
&& (_.isUndefined(value.email) || _.isString(value.email))
|
||||
&& (_.isUndefined(value.password) || _.isString(value.password)),
|
||||
custom: value =>
|
||||
_.isPlainObject(value) &&
|
||||
(_.isUndefined(value.email) || _.isString(value.email)) &&
|
||||
(_.isUndefined(value.password) || _.isString(value.password)),
|
||||
required: true,
|
||||
},
|
||||
request: {
|
||||
|
@ -26,12 +27,14 @@ module.exports = {
|
|||
|
||||
async fn(inputs, exits) {
|
||||
if (!_.isUndefined(inputs.values.email)) {
|
||||
// eslint-disable-next-line no-param-reassign
|
||||
inputs.values.email = inputs.values.email.toLowerCase();
|
||||
}
|
||||
|
||||
let isOnlyPasswordChange = false;
|
||||
|
||||
if (!_.isUndefined(inputs.values.password)) {
|
||||
// eslint-disable-next-line no-param-reassign
|
||||
inputs.values.password = bcrypt.hashSync(inputs.values.password, 10);
|
||||
|
||||
if (Object.keys(inputs.values).length === 1) {
|
||||
|
@ -70,7 +73,7 @@ module.exports = {
|
|||
|
||||
const userIds = _.union([user.id], adminUserIds, userIdsForProject);
|
||||
|
||||
userIds.forEach((userId) => {
|
||||
userIds.forEach(userId => {
|
||||
sails.sockets.broadcast(
|
||||
`user:${userId}`,
|
||||
'userUpdate',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue