diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2017-11-23 18:04:48 +0100 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2017-11-27 19:40:53 +0100 |
commit | d4f1e94c89336255537b0b82913591f00e716201 (patch) | |
tree | c7d18e09a4f53eafc61de8cb0692c020b197512d /server/models | |
parent | 8d468a16fd33ec2660c3c59b3f7def53eb0cc4a1 (diff) | |
download | PeerTube-d4f1e94c89336255537b0b82913591f00e716201.tar.gz PeerTube-d4f1e94c89336255537b0b82913591f00e716201.tar.zst PeerTube-d4f1e94c89336255537b0b82913591f00e716201.zip |
Misc cleanup
Diffstat (limited to 'server/models')
-rw-r--r-- | server/models/server/server.ts | 2 | ||||
-rw-r--r-- | server/models/video/video-file.ts | 16 |
2 files changed, 5 insertions, 13 deletions
diff --git a/server/models/server/server.ts b/server/models/server/server.ts index 75cd5f929..fcd7be090 100644 --- a/server/models/server/server.ts +++ b/server/models/server/server.ts | |||
@@ -44,7 +44,7 @@ export default function (sequelize: Sequelize.Sequelize, DataTypes: Sequelize.Da | |||
44 | ) | 44 | ) |
45 | 45 | ||
46 | const classMethods = [ | 46 | const classMethods = [ |
47 | listBadServers | 47 | updateServersScoreAndRemoveBadOnes |
48 | ] | 48 | ] |
49 | addMethodsToModel(Server, classMethods) | 49 | addMethodsToModel(Server, classMethods) |
50 | 50 | ||
diff --git a/server/models/video/video-file.ts b/server/models/video/video-file.ts index ead7f3e03..600141994 100644 --- a/server/models/video/video-file.ts +++ b/server/models/video/video-file.ts | |||
@@ -1,18 +1,10 @@ | |||
1 | import * as Sequelize from 'sequelize' | ||
2 | import { values } from 'lodash' | 1 | import { values } from 'lodash' |
3 | 2 | import * as Sequelize from 'sequelize' | |
4 | import { CONSTRAINTS_FIELDS } from '../../initializers' | 3 | import { isVideoFileInfoHashValid, isVideoFileResolutionValid, isVideoFileSizeValid } from '../../helpers/custom-validators/videos' |
5 | import { | 4 | import { CONSTRAINTS_FIELDS } from '../../initializers/constants' |
6 | isVideoFileResolutionValid, | ||
7 | isVideoFileSizeValid, | ||
8 | isVideoFileInfoHashValid | ||
9 | } from '../../helpers' | ||
10 | 5 | ||
11 | import { addMethodsToModel } from '../utils' | 6 | import { addMethodsToModel } from '../utils' |
12 | import { | 7 | import { VideoFileAttributes, VideoFileInstance } from './video-file-interface' |
13 | VideoFileInstance, | ||
14 | VideoFileAttributes | ||
15 | } from './video-file-interface' | ||
16 | 8 | ||
17 | let VideoFile: Sequelize.Model<VideoFileInstance, VideoFileAttributes> | 9 | let VideoFile: Sequelize.Model<VideoFileInstance, VideoFileAttributes> |
18 | 10 | ||