Avoid synchronous fetching for remote embedding documents.
This commit is contained in:
parent
5b3e7924f6
commit
a9653fc7c9
|
@ -115,6 +115,11 @@
|
||||||
}
|
}
|
||||||
setup(policy);
|
setup(policy);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if (!this.syncFetchPolicy && this.embeddingDocument) {
|
||||||
|
asyncFetch();
|
||||||
|
return;
|
||||||
|
}
|
||||||
debug(`Synchronously fetching policy for ${url}.`);
|
debug(`Synchronously fetching policy for ${url}.`);
|
||||||
let policy = null;
|
let policy = null;
|
||||||
let attempts = 100;
|
let attempts = 100;
|
||||||
|
|
Loading…
Reference in New Issue