@nomadamas/mailcrawl 0.1.3 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/archive.js +2 -0
- package/package.json +1 -1
package/dist/archive.js
CHANGED
|
@@ -145,6 +145,8 @@ export class Archive {
|
|
|
145
145
|
}
|
|
146
146
|
});
|
|
147
147
|
transaction();
|
|
148
|
+
if (!pending.length)
|
|
149
|
+
return { embedded, reused, archiveRevision: this.revision() };
|
|
148
150
|
const vectors = await embedder.embedDocuments(pending.map((row) => row.text));
|
|
149
151
|
const write = this.db.transaction(() => {
|
|
150
152
|
for (const [index, row] of pending.entries()) {
|