diff options
author | Chocobozzz <me@florianbigard.com> | 2021-07-16 09:04:35 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-07-20 15:27:18 +0200 |
commit | 89d241a79c262b9775c233b73cff080043ebb5e6 (patch) | |
tree | cb3b6cb431d25d891ef4e02f66c61d252d17048f /shared/extra-utils/videos/live-command.ts | |
parent | d23dd9fbfc4d26026352c10f81d2795ceaf2908a (diff) | |
download | PeerTube-89d241a79c262b9775c233b73cff080043ebb5e6.tar.gz PeerTube-89d241a79c262b9775c233b73cff080043ebb5e6.tar.zst PeerTube-89d241a79c262b9775c233b73cff080043ebb5e6.zip |
Shorter server command names
Diffstat (limited to 'shared/extra-utils/videos/live-command.ts')
-rw-r--r-- | shared/extra-utils/videos/live-command.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/shared/extra-utils/videos/live-command.ts b/shared/extra-utils/videos/live-command.ts index 5adf601cc..fd66c9924 100644 --- a/shared/extra-utils/videos/live-command.ts +++ b/shared/extra-utils/videos/live-command.ts | |||
@@ -114,7 +114,7 @@ export class LiveCommand extends AbstractCommand { | |||
114 | const { resolution, segment, videoUUID } = options | 114 | const { resolution, segment, videoUUID } = options |
115 | const segmentName = `${resolution}-00000${segment}.ts` | 115 | const segmentName = `${resolution}-00000${segment}.ts` |
116 | 116 | ||
117 | return this.server.serversCommand.waitUntilLog(`${videoUUID}/${segmentName}`, 2, false) | 117 | return this.server.servers.waitUntilLog(`${videoUUID}/${segmentName}`, 2, false) |
118 | } | 118 | } |
119 | 119 | ||
120 | async waitUntilSaved (options: OverrideCommandOptions & { | 120 | async waitUntilSaved (options: OverrideCommandOptions & { |
@@ -123,7 +123,7 @@ export class LiveCommand extends AbstractCommand { | |||
123 | let video: VideoDetails | 123 | let video: VideoDetails |
124 | 124 | ||
125 | do { | 125 | do { |
126 | video = await this.server.videosCommand.getWithToken({ token: options.token, id: options.videoId }) | 126 | video = await this.server.videos.getWithToken({ token: options.token, id: options.videoId }) |
127 | 127 | ||
128 | await wait(500) | 128 | await wait(500) |
129 | } while (video.isLive === true && video.state.id !== VideoState.PUBLISHED) | 129 | } while (video.isLive === true && video.state.id !== VideoState.PUBLISHED) |
@@ -132,7 +132,7 @@ export class LiveCommand extends AbstractCommand { | |||
132 | async countPlaylists (options: OverrideCommandOptions & { | 132 | async countPlaylists (options: OverrideCommandOptions & { |
133 | videoUUID: string | 133 | videoUUID: string |
134 | }) { | 134 | }) { |
135 | const basePath = this.server.serversCommand.buildDirectory('streaming-playlists') | 135 | const basePath = this.server.servers.buildDirectory('streaming-playlists') |
136 | const hlsPath = join(basePath, 'hls', options.videoUUID) | 136 | const hlsPath = join(basePath, 'hls', options.videoUUID) |
137 | 137 | ||
138 | const files = await readdir(hlsPath) | 138 | const files = await readdir(hlsPath) |
@@ -147,7 +147,7 @@ export class LiveCommand extends AbstractCommand { | |||
147 | let video: VideoDetails | 147 | let video: VideoDetails |
148 | 148 | ||
149 | do { | 149 | do { |
150 | video = await this.server.videosCommand.getWithToken({ token: options.token, id: options.videoId }) | 150 | video = await this.server.videos.getWithToken({ token: options.token, id: options.videoId }) |
151 | 151 | ||
152 | await wait(500) | 152 | await wait(500) |
153 | } while (video.state.id !== options.state) | 153 | } while (video.state.id !== options.state) |