@xk2800/nextjs-template 0.7.2-beta.2 → 0.7.2-beta.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.
@@ -1,5 +1,5 @@
1
1
  import { lookupErrorDetail, unexpectedErrorMessage } from '../chunk-653GF7OT.mjs';
2
- import { auth } from '../chunk-K2GCSLRJ.mjs';
2
+ import { auth } from '../chunk-ONJDPUVO.mjs';
3
3
  import '../chunk-O5EQYHNC.mjs';
4
4
  import '../chunk-6OAHCEDJ.mjs';
5
5
  import { getSystemSettings } from '../chunk-2BJ3B4FR.mjs';
@@ -1256,6 +1256,7 @@ async function promoteFirstAdmin(user) {
1256
1256
  const [existing] = await db.select({ id: users.id }).from(users).where(drizzleOrm.eq(users.role, "admin")).limit(1);
1257
1257
  if (existing) return;
1258
1258
  await db.update(users).set({ role: "admin" }).where(drizzleOrm.eq(users.id, user.id));
1259
+ user.role = "admin";
1259
1260
  }
1260
1261
  function createAuth(overrides = {}) {
1261
1262
  var _a, _b, _c, _d, _e, _f, _g;