mirror of
https://github.com/immich-app/immich
synced 2025-11-14 17:36:12 +00:00
refactor(web): shared link key auth (#3855)
This commit is contained in:
parent
10c2bda3a9
commit
9bbef4a97b
21 changed files with 115 additions and 108 deletions
|
|
@ -58,7 +58,10 @@ export class AssetStore {
|
|||
this.assetToBucket = {};
|
||||
this.albumAssets = new Set();
|
||||
|
||||
const { data: buckets } = await api.assetApi.getTimeBuckets(this.options);
|
||||
const { data: buckets } = await api.assetApi.getTimeBuckets({
|
||||
...this.options,
|
||||
key: api.getKey(),
|
||||
});
|
||||
|
||||
this.buckets = buckets.map((bucket) => {
|
||||
const unwrappedWidth = (3 / 2) * bucket.count * THUMBNAIL_HEIGHT * (7 / 10);
|
||||
|
|
@ -107,7 +110,11 @@ export class AssetStore {
|
|||
bucket.cancelToken = new AbortController();
|
||||
|
||||
const { data: assets } = await api.assetApi.getByTimeBucket(
|
||||
{ ...this.options, timeBucket: bucketDate },
|
||||
{
|
||||
...this.options,
|
||||
timeBucket: bucketDate,
|
||||
key: api.getKey(),
|
||||
},
|
||||
{ signal: bucket.cancelToken.signal },
|
||||
);
|
||||
|
||||
|
|
@ -117,7 +124,7 @@ export class AssetStore {
|
|||
albumId: this.albumId,
|
||||
timeBucket: bucketDate,
|
||||
size: this.options.size,
|
||||
key: this.options.key,
|
||||
key: api.getKey(),
|
||||
},
|
||||
{ signal: bucket.cancelToken.signal },
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue