diff options
author | Chocobozzz <me@florianbigard.com> | 2022-01-18 11:37:29 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2022-01-18 11:37:29 +0100 |
commit | e8bffe9690307f2686ed5573cae2b86ee5f57789 (patch) | |
tree | e6268124e5e9c22eb465d94ad638ed8443bc9743 /client/src/app/shared/shared-video-playlist | |
parent | c1f7a737cfe174ff1648f269a62540826d0e8089 (diff) | |
download | PeerTube-e8bffe9690307f2686ed5573cae2b86ee5f57789.tar.gz PeerTube-e8bffe9690307f2686ed5573cae2b86ee5f57789.tar.zst PeerTube-e8bffe9690307f2686ed5573cae2b86ee5f57789.zip |
Remove unnecessary function
Diffstat (limited to 'client/src/app/shared/shared-video-playlist')
-rw-r--r-- | client/src/app/shared/shared-video-playlist/video-playlist.service.ts | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/client/src/app/shared/shared-video-playlist/video-playlist.service.ts b/client/src/app/shared/shared-video-playlist/video-playlist.service.ts index 44d930b07..db9f78a7a 100644 --- a/client/src/app/shared/shared-video-playlist/video-playlist.service.ts +++ b/client/src/app/shared/shared-video-playlist/video-playlist.service.ts | |||
@@ -154,7 +154,6 @@ export class VideoPlaylistService { | |||
154 | 154 | ||
155 | return this.authHttp.put(VideoPlaylistService.BASE_VIDEO_PLAYLIST_URL + videoPlaylist.id, data) | 155 | return this.authHttp.put(VideoPlaylistService.BASE_VIDEO_PLAYLIST_URL + videoPlaylist.id, data) |
156 | .pipe( | 156 | .pipe( |
157 | map(this.restExtractor.extractDataBool), | ||
158 | tap(() => { | 157 | tap(() => { |
159 | if (!this.myAccountPlaylistCache) return | 158 | if (!this.myAccountPlaylistCache) return |
160 | 159 | ||
@@ -170,7 +169,6 @@ export class VideoPlaylistService { | |||
170 | removeVideoPlaylist (videoPlaylist: VideoPlaylist) { | 169 | removeVideoPlaylist (videoPlaylist: VideoPlaylist) { |
171 | return this.authHttp.delete(VideoPlaylistService.BASE_VIDEO_PLAYLIST_URL + videoPlaylist.id) | 170 | return this.authHttp.delete(VideoPlaylistService.BASE_VIDEO_PLAYLIST_URL + videoPlaylist.id) |
172 | .pipe( | 171 | .pipe( |
173 | map(this.restExtractor.extractDataBool), | ||
174 | tap(() => { | 172 | tap(() => { |
175 | if (!this.myAccountPlaylistCache) return | 173 | if (!this.myAccountPlaylistCache) return |
176 | 174 | ||
@@ -207,7 +205,6 @@ export class VideoPlaylistService { | |||
207 | updateVideoOfPlaylist (playlistId: number, playlistElementId: number, body: VideoPlaylistElementUpdate, videoId: number) { | 205 | updateVideoOfPlaylist (playlistId: number, playlistElementId: number, body: VideoPlaylistElementUpdate, videoId: number) { |
208 | return this.authHttp.put(VideoPlaylistService.BASE_VIDEO_PLAYLIST_URL + playlistId + '/videos/' + playlistElementId, body) | 206 | return this.authHttp.put(VideoPlaylistService.BASE_VIDEO_PLAYLIST_URL + playlistId + '/videos/' + playlistElementId, body) |
209 | .pipe( | 207 | .pipe( |
210 | map(this.restExtractor.extractDataBool), | ||
211 | tap(() => { | 208 | tap(() => { |
212 | const existsResult = this.videoExistsCache[videoId] | 209 | const existsResult = this.videoExistsCache[videoId] |
213 | 210 | ||
@@ -227,7 +224,6 @@ export class VideoPlaylistService { | |||
227 | removeVideoFromPlaylist (playlistId: number, playlistElementId: number, videoId?: number) { | 224 | removeVideoFromPlaylist (playlistId: number, playlistElementId: number, videoId?: number) { |
228 | return this.authHttp.delete(VideoPlaylistService.BASE_VIDEO_PLAYLIST_URL + playlistId + '/videos/' + playlistElementId) | 225 | return this.authHttp.delete(VideoPlaylistService.BASE_VIDEO_PLAYLIST_URL + playlistId + '/videos/' + playlistElementId) |
229 | .pipe( | 226 | .pipe( |
230 | map(this.restExtractor.extractDataBool), | ||
231 | tap(() => { | 227 | tap(() => { |
232 | if (!videoId) return | 228 | if (!videoId) return |
233 | 229 | ||
@@ -249,10 +245,7 @@ export class VideoPlaylistService { | |||
249 | } | 245 | } |
250 | 246 | ||
251 | return this.authHttp.post(VideoPlaylistService.BASE_VIDEO_PLAYLIST_URL + playlistId + '/videos/reorder', body) | 247 | return this.authHttp.post(VideoPlaylistService.BASE_VIDEO_PLAYLIST_URL + playlistId + '/videos/reorder', body) |
252 | .pipe( | 248 | .pipe(catchError(err => this.restExtractor.handleError(err))) |
253 | map(this.restExtractor.extractDataBool), | ||
254 | catchError(err => this.restExtractor.handleError(err)) | ||
255 | ) | ||
256 | } | 249 | } |
257 | 250 | ||
258 | getPlaylistVideos (options: { | 251 | getPlaylistVideos (options: { |