diff options
Diffstat (limited to 'client/src/app/search/search.component.ts')
-rw-r--r-- | client/src/app/search/search.component.ts | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/client/src/app/search/search.component.ts b/client/src/app/search/search.component.ts index a3383ed8a..a7ddbe1f8 100644 --- a/client/src/app/search/search.component.ts +++ b/client/src/app/search/search.component.ts | |||
@@ -1,6 +1,6 @@ | |||
1 | import { Component, OnDestroy, OnInit } from '@angular/core' | 1 | import { Component, OnDestroy, OnInit } from '@angular/core' |
2 | import { ActivatedRoute, Router } from '@angular/router' | 2 | import { ActivatedRoute, Router } from '@angular/router' |
3 | import { AuthService, Notifier, ServerService } from '@app/core' | 3 | import { AuthService, Notifier } from '@app/core' |
4 | import { forkJoin, Subscription } from 'rxjs' | 4 | import { forkJoin, Subscription } from 'rxjs' |
5 | import { SearchService } from '@app/search/search.service' | 5 | import { SearchService } from '@app/search/search.service' |
6 | import { ComponentPagination } from '@app/shared/rest/component-pagination.model' | 6 | import { ComponentPagination } from '@app/shared/rest/component-pagination.model' |
@@ -138,6 +138,10 @@ export class SearchComponent implements OnInit, OnDestroy { | |||
138 | return this.advancedSearch.size() | 138 | return this.advancedSearch.size() |
139 | } | 139 | } |
140 | 140 | ||
141 | removeVideoFromArray (video: Video) { | ||
142 | this.results = this.results.filter(r => !this.isVideo(r) || r.id !== video.id) | ||
143 | } | ||
144 | |||
141 | private resetPagination () { | 145 | private resetPagination () { |
142 | this.pagination.currentPage = 1 | 146 | this.pagination.currentPage = 1 |
143 | this.pagination.totalItems = null | 147 | this.pagination.totalItems = null |