aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2019-03-21 16:49:46 +0100
committerChocobozzz <me@florianbigard.com>2019-04-02 11:45:02 +0200
commit489290b8b16bede6ddfb773adad55dee6471ccfd (patch)
tree8d3bb73c80df18f1e4d15b23a7e4080a6bc5985e /server/models
parent7ccddd7b5250bd25a917a6e77e58b87b9484a2a4 (diff)
downloadPeerTube-489290b8b16bede6ddfb773adad55dee6471ccfd.tar.gz
PeerTube-489290b8b16bede6ddfb773adad55dee6471ccfd.tar.zst
PeerTube-489290b8b16bede6ddfb773adad55dee6471ccfd.zip
Restore videos list components
Diffstat (limited to 'server/models')
-rw-r--r--server/models/video/video-comment.ts3
-rw-r--r--server/models/video/video-share.ts3
2 files changed, 2 insertions, 4 deletions
diff --git a/server/models/video/video-comment.ts b/server/models/video/video-comment.ts
index e733138c1..93d84c6fc 100644
--- a/server/models/video/video-comment.ts
+++ b/server/models/video/video-comment.ts
@@ -1,5 +1,4 @@
1import * as Sequelize from 'sequelize' 1import * as Sequelize from 'sequelize'
2import { Op } from 'sequelize'
3import { 2import {
4 AllowNull, 3 AllowNull,
5 BeforeDestroy, 4 BeforeDestroy,
@@ -458,7 +457,7 @@ export class VideoCommentModel extends Model<VideoCommentModel> {
458 const query = { 457 const query = {
459 where: { 458 where: {
460 updatedAt: { 459 updatedAt: {
461 [Op.lt]: beforeUpdatedAt 460 [Sequelize.Op.lt]: beforeUpdatedAt
462 }, 461 },
463 videoId 462 videoId
464 } 463 }
diff --git a/server/models/video/video-share.ts b/server/models/video/video-share.ts
index fb52b35d9..399081564 100644
--- a/server/models/video/video-share.ts
+++ b/server/models/video/video-share.ts
@@ -1,5 +1,4 @@
1import * as Sequelize from 'sequelize' 1import * as Sequelize from 'sequelize'
2import { Op } from 'sequelize'
3import * as Bluebird from 'bluebird' 2import * as Bluebird from 'bluebird'
4import { AllowNull, BelongsTo, Column, CreatedAt, DataType, ForeignKey, Is, Model, Scopes, Table, UpdatedAt } from 'sequelize-typescript' 3import { AllowNull, BelongsTo, Column, CreatedAt, DataType, ForeignKey, Is, Model, Scopes, Table, UpdatedAt } from 'sequelize-typescript'
5import { isActivityPubUrlValid } from '../../helpers/custom-validators/activitypub/misc' 4import { isActivityPubUrlValid } from '../../helpers/custom-validators/activitypub/misc'
@@ -206,7 +205,7 @@ export class VideoShareModel extends Model<VideoShareModel> {
206 const query = { 205 const query = {
207 where: { 206 where: {
208 updatedAt: { 207 updatedAt: {
209 [Op.lt]: beforeUpdatedAt 208 [Sequelize.Op.lt]: beforeUpdatedAt
210 }, 209 },
211 videoId 210 videoId
212 } 211 }