X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Fmiddlewares%2Fvalidators%2Ffeeds.ts;h=51e6d6fffde91a48e53afb2462591d0ff1720d44;hb=c756bae079e02873f6433582ca14a092fec0db27;hp=aa16cc99378b2148eeaf4846f9d62e1c3d6df172;hpb=76148b27f7501bac061992136852be4303370c8d;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/middlewares/validators/feeds.ts b/server/middlewares/validators/feeds.ts index aa16cc993..51e6d6fff 100644 --- a/server/middlewares/validators/feeds.ts +++ b/server/middlewares/validators/feeds.ts @@ -1,18 +1,18 @@ import * as express from 'express' import { param, query } from 'express-validator' +import { HttpStatusCode } from '../../../shared/core-utils/miscs/http-error-codes' import { isValidRSSFeed } from '../../helpers/custom-validators/feeds' import { exists, isIdOrUUIDValid, isIdValid } from '../../helpers/custom-validators/misc' import { logger } from '../../helpers/logger' import { + areValidationErrors, doesAccountIdExist, doesAccountNameWithHostExist, doesUserFeedTokenCorrespond, doesVideoChannelIdExist, - doesVideoChannelNameWithHostExist -} from '../../helpers/middlewares' -import { doesVideoExist } from '../../helpers/middlewares/videos' -import { areValidationErrors } from './utils' -import { HttpStatusCode } from '../../../shared/core-utils/miscs/http-error-codes' + doesVideoChannelNameWithHostExist, + doesVideoExist +} from './shared' const feedsFormatValidator = [ param('format').optional().custom(isValidRSSFeed).withMessage('Should have a valid format (rss, atom, json)'),