summaryrefslogtreecommitdiffstats
path: root/ui/src/utils.ts
diff options
context:
space:
mode:
authorDessalines <tyhou13@gmx.com>2020-06-03 11:41:22 -0400
committerDessalines <tyhou13@gmx.com>2020-06-03 11:41:22 -0400
commit2deb0b3d7f079f707715d780310e0f4ef37ef59a (patch)
treea4037c354ffd3f83dceaee7d4926fca400570786 /ui/src/utils.ts
parentb1b9568c96ca2d0371d28171687af9a5f63ef959 (diff)
Adding webp for pictshare images / avatars. Fixes #772
Diffstat (limited to 'ui/src/utils.ts')
-rw-r--r--ui/src/utils.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/ui/src/utils.ts b/ui/src/utils.ts
index bb1b6d90..190fcf57 100644
--- a/ui/src/utils.ts
+++ b/ui/src/utils.ts
@@ -423,7 +423,7 @@ export function objectFlip(obj: any) {
export function pictshareAvatarThumbnail(src: string): string {
// sample url: http://localhost:8535/pictshare/gs7xuu.jpg
let split = src.split('pictshare');
- let out = `${split[0]}pictshare/96${split[1]}`;
+ let out = `${split[0]}pictshare/webp/96${split[1]}`;
return out;
}
@@ -448,7 +448,7 @@ export function pictshareImage(
hash = split[1];
}
- let out = `${root}/${thumbnail ? '192/' : ''}${hash}`;
+ let out = `${root}/webp/${thumbnail ? '192/' : ''}${hash}`;
return out;
}