We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 74e8342 commit 5dc05bbCopy full SHA for 5dc05bb
src/sources/cachingSource.ts
@@ -11,7 +11,7 @@ type CacheOptions = Omit<Options, "url"> & {
11
12
const getShouldCache = async (layer: { name: string }) => {
13
const store = await getCurrentSettings();
14
- return store.layers[layer.name].cache;
+ return store.layers?.[layer.name]?.cache ?? false;
15
}
16
17
export const getCacheId = (props: { name }, tile: TileCoord) => `${props.name}/${tile[2]}/${tile[0]}/${tile[1]}`;
0 commit comments