aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/server-commands/miscs
diff options
context:
space:
mode:
Diffstat (limited to 'shared/server-commands/miscs')
-rw-r--r--shared/server-commands/miscs/sql-command.ts13
1 files changed, 13 insertions, 0 deletions
diff --git a/shared/server-commands/miscs/sql-command.ts b/shared/server-commands/miscs/sql-command.ts
index dbc441aba..823fc9e38 100644
--- a/shared/server-commands/miscs/sql-command.ts
+++ b/shared/server-commands/miscs/sql-command.ts
@@ -86,6 +86,8 @@ export class SQLCommand extends AbstractCommand {
86 return seq.query(query, options) 86 return seq.query(query, options)
87 } 87 }
88 88
89 // ---------------------------------------------------------------------------
90
89 setPluginField (pluginName: string, field: string, value: string) { 91 setPluginField (pluginName: string, field: string, value: string) {
90 const seq = this.getSequelize() 92 const seq = this.getSequelize()
91 93
@@ -102,6 +104,17 @@ export class SQLCommand extends AbstractCommand {
102 return this.setPluginField(pluginName, 'latestVersion', newVersion) 104 return this.setPluginField(pluginName, 'latestVersion', newVersion)
103 } 105 }
104 106
107 // ---------------------------------------------------------------------------
108
109 async getPlaylistInfohash (playlistId: number) {
110 const result = await this.selectQuery('SELECT "p2pMediaLoaderInfohashes" FROM "videoStreamingPlaylist" WHERE id = ' + playlistId)
111 if (!result || result.length === 0) return []
112
113 return result[0].p2pMediaLoaderInfohashes
114 }
115
116 // ---------------------------------------------------------------------------
117
105 setActorFollowScores (newScore: number) { 118 setActorFollowScores (newScore: number) {
106 const seq = this.getSequelize() 119 const seq = this.getSequelize()
107 120