@effectify/node-better-auth 0.4.2 → 0.4.3

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.
@@ -15,7 +15,11 @@ export var AuthService;
15
15
  ? String(options.database.name || 'unknown')
16
16
  : 'unknown';
17
17
  yield* Effect.logInfo(`Creating auth instance with database path: ${dbPathForLog}`);
18
- const isAdapter = options.database && typeof options.database === 'object' && 'createSession' in options.database;
18
+ const isAdapter = options.database &&
19
+ typeof options.database === 'object' &&
20
+ ('createSession' in options.database || 'createUser' in options.database);
21
+ yield* Effect.logInfo(`DEBUG: options.database keys: ${JSON.stringify(Object.keys(options.database || {}))}`);
22
+ yield* Effect.logInfo(`DEBUG: isAdapter detection result: ${isAdapter}`);
19
23
  if (!isAdapter) {
20
24
  const { runMigrations } = yield* Effect.promise(() => getMigrations(options));
21
25
  yield* Effect.promise(runMigrations);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@effectify/node-better-auth",
3
- "version": "0.4.2",
3
+ "version": "0.4.3",
4
4
  "description": "Integration of better-auth with Effect for Node.js applications",
5
5
  "type": "module",
6
6
  "main": "./dist/src/index.js",