From 7d8e778ad031873b2bcc273d281baf6559610f71 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Mon, 7 May 2018 11:31:23 +0200 Subject: Fix video channel update/create on empty fields --- server/middlewares/validators/video-channels.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'server/middlewares/validators') diff --git a/server/middlewares/validators/video-channels.ts b/server/middlewares/validators/video-channels.ts index 3af20a1b4..92c0de419 100644 --- a/server/middlewares/validators/video-channels.ts +++ b/server/middlewares/validators/video-channels.ts @@ -4,14 +4,15 @@ import { UserRight } from '../../../shared' import { isAccountIdExist } from '../../helpers/custom-validators/accounts' import { isIdOrUUIDValid } from '../../helpers/custom-validators/misc' import { - isVideoChannelDescriptionValid, isVideoChannelExist, - isVideoChannelNameValid, isVideoChannelSupportValid + isVideoChannelDescriptionValid, + isVideoChannelExist, + isVideoChannelNameValid, + isVideoChannelSupportValid } from '../../helpers/custom-validators/video-channels' import { logger } from '../../helpers/logger' import { UserModel } from '../../models/account/user' import { VideoChannelModel } from '../../models/video/video-channel' import { areValidationErrors } from './utils' -import { AccountModel } from '../../models/account/account' const listVideoAccountChannelsValidator = [ param('accountId').custom(isIdOrUUIDValid).withMessage('Should have a valid account id'), -- cgit v1.2.3