Compare commits

..
1 Commits
Author SHA1 Message Date
ztimson 60bceb195f Fix name
Publish Library / Build NPM Project (push) Successful in 1m35s
Publish Library / Tag Version (push) Successful in 8s
2026-10-05 23:14:14 -04:00
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@ztimson/zim-utils",
"version": "0.4.12",
"version": "0.4.13",
"description": "Native, dependency-light ZIM archive reader/searcher and Kiwix catalog downloader for Node.js",
"author": "Zak Timson",
"license": "MIT",
+2 -2
View File
@@ -131,7 +131,7 @@ export class ZimManager {
async catalog(search, opts = {}) {
const results = await zimCatalog(search, {url: this.#catalogUrl, ...opts});
return results.map(entry => this.#active[entry.href]
? {...entry, ...this.#active[entry.href].dl.meta, downloading: true}
? {...this.#active[entry.href].dl.meta, ...entry, downloading: true}
: entry);
}
@@ -201,7 +201,7 @@ export class ZimManager {
const localNames = new Set(local.map(l => l.name));
const pending = Object.values(this.#active)
.filter(({entry}) => !localNames.has(entry.name))
.map(({entry, dl}) => ({...entry, ...dl.meta, downloading: true}));
.map(({entry, dl}) => ({...dl.meta, ...entry, downloading: true}));
return [...local, ...pending];
}