We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 006f574 commit f24cff3Copy full SHA for f24cff3
src/models/MediaMetadata.ts
@@ -51,6 +51,8 @@ const isTypeEpisode = function(context?: MediaMetadataInterface): boolean {
51
return context ? context.type === 'episode' : this.type === 'episode';
52
};
53
54
+const ONE_DAY_IN_SECONDS = 86400; // 1 day
55
+
56
const MediaMetadataSchema: Schema = new Schema({
57
actors: { type: Array },
58
awards: { type: String },
@@ -59,9 +61,10 @@ const MediaMetadataSchema: Schema = new Schema({
59
61
collectionTmdbID: { type: Number },
60
62
country: { type: String },
63
createdAt: {
- type: Date,
64
default: Date.now,
65
+ expires: ONE_DAY_IN_SECONDS,
66
select: false,
67
+ type: Date,
68
},
69
credits: { type: Array },
70
directors: { type: Array },
0 commit comments