Refactoring 2
This commit is contained in:
parent
dd14dfe72e
commit
e4b78ceec2
76 changed files with 870 additions and 734 deletions
13
packages/bridge-common/lib/utils.ts
Normal file
13
packages/bridge-common/lib/utils.ts
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
import { makeWorkerUtils, WorkerUtils } from "graphile-worker";
|
||||
|
||||
let workerUtils: WorkerUtils;
|
||||
|
||||
export const getWorkerUtils = async () => {
|
||||
if (!workerUtils) {
|
||||
workerUtils = await makeWorkerUtils({
|
||||
connectionString: process.env.DATABASE_URL,
|
||||
});
|
||||
}
|
||||
|
||||
return workerUtils;
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue