diff options
Diffstat (limited to 'client/src/app/shared/shared-abuse-list/abuse-list-table.component.ts')
-rw-r--r-- | client/src/app/shared/shared-abuse-list/abuse-list-table.component.ts | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/client/src/app/shared/shared-abuse-list/abuse-list-table.component.ts b/client/src/app/shared/shared-abuse-list/abuse-list-table.component.ts index 297993e39..10f5861b9 100644 --- a/client/src/app/shared/shared-abuse-list/abuse-list-table.component.ts +++ b/client/src/app/shared/shared-abuse-list/abuse-list-table.component.ts | |||
@@ -1,8 +1,6 @@ | |||
1 | import * as debug from 'debug' | 1 | import * as debug from 'debug' |
2 | import truncate from 'lodash-es/truncate' | 2 | import truncate from 'lodash-es/truncate' |
3 | import { SortMeta } from 'primeng/api' | 3 | import { SortMeta } from 'primeng/api' |
4 | import { buildVideoOrPlaylistEmbed } from 'src/assets/player/utils' | ||
5 | import { environment } from 'src/environments/environment' | ||
6 | import { Component, Input, OnInit, ViewChild } from '@angular/core' | 4 | import { Component, Input, OnInit, ViewChild } from '@angular/core' |
7 | import { DomSanitizer } from '@angular/platform-browser' | 5 | import { DomSanitizer } from '@angular/platform-browser' |
8 | import { ActivatedRoute, Router } from '@angular/router' | 6 | import { ActivatedRoute, Router } from '@angular/router' |
@@ -10,7 +8,6 @@ import { ConfirmService, MarkdownService, Notifier, RestPagination, RestTable } | |||
10 | import { Account, Actor, DropdownAction, Video, VideoService } from '@app/shared/shared-main' | 8 | import { Account, Actor, DropdownAction, Video, VideoService } from '@app/shared/shared-main' |
11 | import { AbuseService, BlocklistService, VideoBlockService } from '@app/shared/shared-moderation' | 9 | import { AbuseService, BlocklistService, VideoBlockService } from '@app/shared/shared-moderation' |
12 | import { VideoCommentService } from '@app/shared/shared-video-comment' | 10 | import { VideoCommentService } from '@app/shared/shared-video-comment' |
13 | import { buildVideoEmbedLink, decorateVideoLink } from '@shared/core-utils' | ||
14 | import { AbuseState, AdminAbuse } from '@shared/models' | 11 | import { AbuseState, AdminAbuse } from '@shared/models' |
15 | import { AdvancedInputFilter } from '../shared-forms' | 12 | import { AdvancedInputFilter } from '../shared-forms' |
16 | import { AbuseMessageModalComponent } from './abuse-message-modal.component' | 13 | import { AbuseMessageModalComponent } from './abuse-message-modal.component' |
@@ -133,19 +130,6 @@ export class AbuseListTableComponent extends RestTable implements OnInit { | |||
133 | return '/a/' + abuse.flaggedAccount.nameWithHost | 130 | return '/a/' + abuse.flaggedAccount.nameWithHost |
134 | } | 131 | } |
135 | 132 | ||
136 | getVideoEmbed (abuse: AdminAbuse) { | ||
137 | return buildVideoOrPlaylistEmbed( | ||
138 | decorateVideoLink({ | ||
139 | url: buildVideoEmbedLink(abuse.video, environment.originServerUrl), | ||
140 | title: false, | ||
141 | warningTitle: false, | ||
142 | startTime: abuse.video.startAt, | ||
143 | stopTime: abuse.video.endAt | ||
144 | }), | ||
145 | abuse.video.name | ||
146 | ) | ||
147 | } | ||
148 | |||
149 | async removeAbuse (abuse: AdminAbuse) { | 133 | async removeAbuse (abuse: AdminAbuse) { |
150 | const res = await this.confirmService.confirm($localize`Do you really want to delete this abuse report?`, $localize`Delete`) | 134 | const res = await this.confirmService.confirm($localize`Do you really want to delete this abuse report?`, $localize`Delete`) |
151 | if (res === false) return | 135 | if (res === false) return |
@@ -220,8 +204,6 @@ export class AbuseListTableComponent extends RestTable implements OnInit { | |||
220 | } | 204 | } |
221 | 205 | ||
222 | if (abuse.video) { | 206 | if (abuse.video) { |
223 | abuse.embedHtml = this.sanitizer.bypassSecurityTrustHtml(this.getVideoEmbed(abuse)) | ||
224 | |||
225 | if (abuse.video.channel?.ownerAccount) { | 207 | if (abuse.video.channel?.ownerAccount) { |
226 | abuse.video.channel.ownerAccount = new Account(abuse.video.channel.ownerAccount) | 208 | abuse.video.channel.ownerAccount = new Account(abuse.video.channel.ownerAccount) |
227 | } | 209 | } |