@ -488,10 +488,9 @@ class LokiSnodeAPI {
async buildNewOnionPaths() {
// this function may be called concurrently make sure we only have one inflight
return primitives.allowOnlyOneAtATime(
'buildNewOnionPaths',
this.buildNewOnionPathsWorker
);
return primitives.allowOnlyOneAtATime('buildNewOnionPaths', async () => {
await this.buildNewOnionPathsWorker();
});
}
async getRandomSnodeAddress() {