aboutsummaryrefslogtreecommitdiff
path: root/viewer/src/services/indexsearch.ts
diff options
context:
space:
mode:
authorZero~Informatique2020-06-28 14:03:04 +0200
committerZero~Informatique2020-06-28 14:11:44 +0200
commit303929136ca6446f538fcfc80ce26626c726f759 (patch)
tree4a88ad565d0feb8f4db0b55a5c1403a06db2ad94 /viewer/src/services/indexsearch.ts
parent170d7a61f720ece9dc4b347b19f5a8213f1d8984 (diff)
downloadldgallery-303929136ca6446f538fcfc80ce26626c726f759.tar.gz
viewer: dependancies update
Diffstat (limited to 'viewer/src/services/indexsearch.ts')
-rw-r--r--viewer/src/services/indexsearch.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/viewer/src/services/indexsearch.ts b/viewer/src/services/indexsearch.ts
index e6d7eed..00f8cfc 100644
--- a/viewer/src/services/indexsearch.ts
+++ b/viewer/src/services/indexsearch.ts
@@ -29,7 +29,7 @@ export default class IndexSearch {
29 } 29 }
30 30
31 private static extractTagsByOperation(searchTags: Tag.Search[]): Tag.SearchByOperation { 31 private static extractTagsByOperation(searchTags: Tag.Search[]): Tag.SearchByOperation {
32 let byOperation: Tag.SearchByOperation = {}; 32 const byOperation: Tag.SearchByOperation = {};
33 Object.values(Operation).forEach( 33 Object.values(Operation).forEach(
34 operation => (byOperation[operation] = searchTags.filter(tag => tag.operation === operation)) 34 operation => (byOperation[operation] = searchTags.filter(tag => tag.operation === operation))
35 ); 35 );
@@ -37,7 +37,7 @@ export default class IndexSearch {
37 } 37 }
38 38
39 private static extractIntersection(byOperation: Tag.SearchByOperation): Set<Gallery.Item> { 39 private static extractIntersection(byOperation: Tag.SearchByOperation): Set<Gallery.Item> {
40 let intersection = new Set<Gallery.Item>(); 40 const intersection = new Set<Gallery.Item>();
41 if (byOperation[Operation.INTERSECTION].length > 0) { 41 if (byOperation[Operation.INTERSECTION].length > 0) {
42 byOperation[Operation.INTERSECTION] 42 byOperation[Operation.INTERSECTION]
43 .map(tag => tag.items) 43 .map(tag => tag.items)
@@ -49,7 +49,7 @@ export default class IndexSearch {
49 } 49 }
50 50
51 private static extractSubstraction(byOperation: Tag.SearchByOperation): Set<Gallery.Item> { 51 private static extractSubstraction(byOperation: Tag.SearchByOperation): Set<Gallery.Item> {
52 let substraction = new Set<Gallery.Item>(); 52 const substraction = new Set<Gallery.Item>();
53 if (byOperation[Operation.SUBSTRACTION].length > 0) { 53 if (byOperation[Operation.SUBSTRACTION].length > 0) {
54 byOperation[Operation.SUBSTRACTION].flatMap(tag => tag.items).forEach(item => substraction.add(item)); 54 byOperation[Operation.SUBSTRACTION].flatMap(tag => tag.items).forEach(item => substraction.add(item));
55 } 55 }