1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-06 03:50:26 +02:00

Move models to typescript-sequelize

This commit is contained in:
Chocobozzz 2017-12-12 17:53:50 +01:00
parent c893d4514e
commit 3fd3ab2d34
No known key found for this signature in database
GPG key ID: 583A612D890159BE
150 changed files with 3676 additions and 5074 deletions

View file

@ -1,9 +1,7 @@
import * as express from 'express'
import { CONFIG, EMBED_SIZE, PREVIEWS_SIZE } from '../initializers'
import { oembedValidator } from '../middlewares'
import { asyncMiddleware } from '../middlewares/async'
import { VideoInstance } from '../models'
import { asyncMiddleware, oembedValidator } from '../middlewares'
import { VideoModel } from '../models/video/video'
const servicesRouter = express.Router()
@ -21,7 +19,7 @@ export {
// ---------------------------------------------------------------------------
function generateOEmbed (req: express.Request, res: express.Response, next: express.NextFunction) {
const video = res.locals.video as VideoInstance
const video = res.locals.video as VideoModel
const webserverUrl = CONFIG.WEBSERVER.URL
const maxHeight = parseInt(req.query.maxheight, 10)
const maxWidth = parseInt(req.query.maxwidth, 10)