From 0b45f59a5a0a04ce668404b602b2df924bff0879 Mon Sep 17 00:00:00 2001 From: chee Date: Fri, 9 Aug 2024 11:28:00 +0100 Subject: [PATCH] Remove .init call from fullfat.ts (#372) This has meant that `automerge-repo` couldn't even be _imported_ in an environment without access to `crypto.getRandomValues` (for example, outside the handler of a Cloudflare worker) because it needs to generate ids. `init` is called correctly already any time a document is created or loaded, so this is only a bug fix and shouldn't have any other effects --- packages/automerge-repo/src/entrypoints/fullfat.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/automerge-repo/src/entrypoints/fullfat.ts b/packages/automerge-repo/src/entrypoints/fullfat.ts index 5e496a67e..3f35abd40 100644 --- a/packages/automerge-repo/src/entrypoints/fullfat.ts +++ b/packages/automerge-repo/src/entrypoints/fullfat.ts @@ -7,5 +7,4 @@ export * from "../index.js" // disable // // eslint-disable-next-line automerge-slimport/enforce-automerge-slim-import -import { next as Am } from "@automerge/automerge" -Am.init() +import "@automerge/automerge"