dorkos 0.124.0 → 0.124.1

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.
Files changed (311) hide show
  1. package/dist/bin/cli.js +935 -551
  2. package/dist/browser/native/package-manifest.json +1 -1
  3. package/dist/browser/source-manifest.json +1 -1
  4. package/dist/client/assets/{AboutPage-BH8Ndn3e.js → AboutPage-DHaZvsJE.js} +1 -1
  5. package/dist/client/assets/{ActivityErrorState-K5Mew9EX.js → ActivityErrorState-BP-qFk2S.js} +1 -1
  6. package/dist/client/assets/{ActivityPage-BB20L5HU.js → ActivityPage-Bme3TzdQ.js} +1 -1
  7. package/dist/client/assets/{ActivityRow-C5O7rnmS.js → ActivityRow-BRZyW9MA.js} +1 -1
  8. package/dist/client/assets/{AdapterIcon-Bmybvrzb.js → AdapterIcon-BcfquTja.js} +1 -1
  9. package/dist/client/assets/{AdapterSetupWizard-CkdV7Hhh.js → AdapterSetupWizard-B4I23pBg.js} +1 -1
  10. package/dist/client/assets/{AgentOptionRow-BA2cDa7r.js → AgentOptionRow-Cb34LtmH.js} +1 -1
  11. package/dist/client/assets/{AgentPicker-CsIIPGZJ.js → AgentPicker-ouNRFSDh.js} +1 -1
  12. package/dist/client/assets/{AgentRequestCard-0fOxvaoe.js → AgentRequestCard-B6MHIsxa.js} +2 -2
  13. package/dist/client/assets/{AppearancePage-XOjkkoli.js → AppearancePage-CutehigK.js} +1 -1
  14. package/dist/client/assets/ApplyToOverridesDialog-B-wIUI27.js +1 -0
  15. package/dist/client/assets/{AttentionSignalRow-CjjZobp7.js → AttentionSignalRow-B1aMjgX_.js} +1 -1
  16. package/dist/client/assets/{BaseTanStackRouterDevtoolsPanel-B-iktbLX-9TVHyRPJ.js → BaseTanStackRouterDevtoolsPanel-B-iktbLX-CdWF4WLz.js} +1 -1
  17. package/dist/client/assets/{BindingDialog-DLoAQauL.js → BindingDialog-BAdueON5.js} +1 -1
  18. package/dist/client/assets/{BlintzCanvas-CYHsXAcY.js → BlintzCanvas-b30dG4gx.js} +3 -3
  19. package/dist/client/assets/{CanvasCsvContent--Gr7Fe_U.js → CanvasCsvContent-DGHgSikG.js} +1 -1
  20. package/dist/client/assets/{CanvasFileContent-estXyAbr.js → CanvasFileContent-D1bFaUeh.js} +2 -2
  21. package/dist/client/assets/{CanvasModel3dContent-CkOo930M.js → CanvasModel3dContent-dST7g1v2.js} +2 -2
  22. package/dist/client/assets/{ChatAppsOff-D4L1zJVN.js → ChatAppsOff-DiObvmJS.js} +1 -1
  23. package/dist/client/assets/{CodeMirrorDiff-DY_6ju-z.js → CodeMirrorDiff-BncI1OY1.js} +1 -1
  24. package/dist/client/assets/{CodeMirrorEditor-BUoDBsBv.js → CodeMirrorEditor-DV6psv19.js} +1 -1
  25. package/dist/client/assets/{CommitmentList-wDkcVP9c.js → CommitmentList-Dx_Ek_Gl.js} +1 -1
  26. package/dist/client/assets/{CommitmentsPage-CzSM6b8R.js → CommitmentsPage-Bca8NMUa.js} +1 -1
  27. package/dist/client/assets/{ComputerResourceView-cERD9H2L.js → ComputerResourceView-DNVNFTdn.js} +1 -1
  28. package/dist/client/assets/{ComputerViewer-rMcfbk2_.js → ComputerViewer-D8SxJdMm.js} +1 -1
  29. package/dist/client/assets/{ConnectionAccessLists-f7QeQbQo.js → ConnectionAccessLists-Bhj1YT15.js} +1 -1
  30. package/dist/client/assets/{ConnectionsPage-BmjtA6pw.js → ConnectionsPage-B20JZxoK.js} +1 -1
  31. package/dist/client/assets/{ConventionPage-CH-ah6nI.js → ConventionPage-De645wxU.js} +1 -1
  32. package/dist/client/assets/{ExtensionPageRoute-CJIxa6ST.js → ExtensionPageRoute-nTeiOBRQ.js} +1 -1
  33. package/dist/client/assets/{FloatingTanStackRouterDevtools-CqogiFob-BP7EJ2JL.js → FloatingTanStackRouterDevtools-CqogiFob-DM79UITv.js} +1 -1
  34. package/dist/client/assets/HandlePage-B08V-om7.js +1 -0
  35. package/dist/client/assets/{HeartbeatPage-BUsf-qrU.js → HeartbeatPage-CBoUxz6t.js} +1 -1
  36. package/dist/client/assets/{KeyEntry-C2kWdN8q.js → KeyEntry-Cug8ocpX.js} +1 -1
  37. package/dist/client/assets/{LexicalField-CR8ulsI_.js → LexicalField-Bv_ogmAq.js} +1 -1
  38. package/dist/client/assets/{ManagesPage-DTtsIOGi.js → ManagesPage-DfJBQKK3.js} +1 -1
  39. package/dist/client/assets/{Marketplace-iaV5XAzv.js → Marketplace-swCVUbdY.js} +2 -2
  40. package/dist/client/assets/{MarketplaceSourcesView-6tgzUfFj.js → MarketplaceSourcesView-CDZDChpV.js} +1 -1
  41. package/dist/client/assets/{McpAppFrame-C7eYYdI9.js → McpAppFrame-BM9cNPPd.js} +1 -1
  42. package/dist/client/assets/{McpSigninBody-BDyGbJ7I.js → McpSigninBody-DKyUKrEE.js} +1 -1
  43. package/dist/client/assets/{Model3dViewer-BujDNuVS.js → Model3dViewer-rXSL5y2P.js} +1 -1
  44. package/dist/client/assets/NamePage-JwMDK1JD.js +1 -0
  45. package/dist/client/assets/{NewDirectMessageMenu-D4e-z2Jt.js → NewDirectMessageMenu-GCEMS5oV.js} +1 -1
  46. package/dist/client/assets/{NotificationsPage-CkDeTaJp.js → NotificationsPage-DSWsOVLa.js} +1 -1
  47. package/dist/client/assets/{OpenMeshSwitch-CtbOt3r5.js → OpenMeshSwitch-BTuctDj4.js} +1 -1
  48. package/dist/client/assets/{OperatorIdentityForm-Vr4qZnmM.js → OperatorIdentityForm-ODDMd2YN.js} +1 -1
  49. package/dist/client/assets/PermissionHistory-41a58Se7.js +1 -0
  50. package/dist/client/assets/{PermissionsPage-f4QaX8oM.js → PermissionsPage-DefmymZ6.js} +1 -1
  51. package/dist/client/assets/{PersonalityPopover-BkZruwF-.js → PersonalityPopover-7zPVBI1I.js} +1 -1
  52. package/dist/client/assets/PhotoPage-DlOVhkW9.js +1 -0
  53. package/dist/client/assets/{PreviewRefusedNotice-BXC2K0tx.js → PreviewRefusedNotice-CwGlBJ7U.js} +1 -1
  54. package/dist/client/assets/{ProfileFields-BebX5oiv.js → ProfileFields-DVMkpJSb.js} +1 -1
  55. package/dist/client/assets/{ProfilePanelContainer-DZoL65zQ.js → ProfilePanelContainer-RrhoPD3T.js} +1 -1
  56. package/dist/client/assets/{ProfileRolePicker-D9H7wsuT.js → ProfileRolePicker-CXRVBCAu.js} +1 -1
  57. package/dist/client/assets/{PromptSuggestionChips-B5fDmc-g.js → PromptSuggestionChips-bBroJdTi.js} +1 -1
  58. package/dist/client/assets/{ReportsToPopover-uVYhSqj7.js → ReportsToPopover-CfPatsWM.js} +1 -1
  59. package/dist/client/assets/{RoomSurface-Bg5WV4Ep.js → RoomSurface-CdgCdV6h.js} +11 -11
  60. package/dist/client/assets/{RoomsPage-yflYFulU.js → RoomsPage-C3dDp1Mb.js} +1 -1
  61. package/dist/client/assets/{RunsOnPopover-DtGrX1Vq.js → RunsOnPopover-BcKjfQi-.js} +1 -1
  62. package/dist/client/assets/{RuntimeConnectFlow-DjReuQ-T.js → RuntimeConnectFlow-DCIRnvOH.js} +1 -1
  63. package/dist/client/assets/{RuntimeSetupDialog-Cr4GRi8c.js → RuntimeSetupDialog-Bg-0b-LC.js} +1 -1
  64. package/dist/client/assets/SeenDevices-nMsGUQTv.js +19 -0
  65. package/dist/client/assets/{SessionsPage-BWu-en78.js → SessionsPage-Cqfx4FGW.js} +1 -1
  66. package/dist/client/assets/SettingsDialog-C8r2igJ_.js +12 -0
  67. package/dist/client/assets/{SkillsPage-BdUb9SZy.js → SkillsPage-BleHQavF.js} +1 -1
  68. package/dist/client/assets/{TaskDialogWrapper-qYJPEoSR.js → TaskDialogWrapper-BhTEvf-u.js} +1 -1
  69. package/dist/client/assets/{TasksEmptyState-Bgcg9vxF.js → TasksEmptyState-Bprx1k8M.js} +2 -2
  70. package/dist/client/assets/{TasksPage-Ch5W2WQS.js → TasksPage-Dub39yEJ.js} +1 -1
  71. package/dist/client/assets/{TeamComputerEntry-CPwSIMRw.js → TeamComputerEntry-CJ-NG0u5.js} +1 -1
  72. package/dist/client/assets/ToolsPage-IsD6M-ZW.js +2 -0
  73. package/dist/client/assets/{TopologyGraph-I4_mkMHM.js → TopologyGraph-CwyasvFI.js} +14 -14
  74. package/dist/client/assets/{TourHost-BPaSwh9I.js → TourHost-BYfztuPb.js} +1 -1
  75. package/dist/client/assets/{UnlinkDialog-BUWZUu5P.js → UnlinkDialog-BKhgxVdF.js} +1 -1
  76. package/dist/client/assets/{WidgetErrorCard-cS8yMCxU.js → WidgetErrorCard-1NyzIJBj.js} +6 -6
  77. package/dist/client/assets/_shell-Ct2Bz7D0.js +80 -0
  78. package/dist/client/assets/{_shell._home-DCA5k-jb.js → _shell._home-xWj7wO5z.js} +1 -1
  79. package/dist/client/assets/{_shell._home.activity-BX4nFLna.js → _shell._home.activity-BqcLoaB1.js} +1 -1
  80. package/dist/client/assets/{_shell._home.index-C8t8cw72.js → _shell._home.index-D4sQsKKk.js} +1 -1
  81. package/dist/client/assets/{_shell._home.tasks-BgUeEvhK.js → _shell._home.tasks--UhQB6h3.js} +1 -1
  82. package/dist/client/assets/{_shell._home.workspaces-BPBdnkRt.js → _shell._home.workspaces-BPFD8Of2.js} +1 -1
  83. package/dist/client/assets/{_shell.channels-CX4kki7G.js → _shell.channels-CnFdvRzc.js} +4 -4
  84. package/dist/client/assets/{_shell.connections-0vP7g7E4.js → _shell.connections-Ik01wS5M.js} +1 -1
  85. package/dist/client/assets/{_shell.feedback-requests-TsuaO4eR.js → _shell.feedback-requests-Czu42kzo.js} +1 -1
  86. package/dist/client/assets/_shell.marketplace-Cezv-i16.js +1 -0
  87. package/dist/client/assets/_shell.marketplace_.sources-BTENmr4W.js +1 -0
  88. package/dist/client/assets/_shell.session-BjevHF_O.js +63 -0
  89. package/dist/client/assets/{_shell.team-Bm6cOBhR.js → _shell.team-UfaJqohh.js} +3 -3
  90. package/dist/client/assets/_shell.x._extensionId-0OO_Xr72.js +1 -0
  91. package/dist/client/assets/_shell.x._extensionId_._-0OO_Xr72.js +1 -0
  92. package/dist/client/assets/{abnfDiagram-WEYOIA3C-CrvoN15x.js → abnfDiagram-WEYOIA3C-oxkfGyl6.js} +1 -1
  93. package/dist/client/assets/{access-copy-B3yNZ7Gz.js → access-copy-Dggxx2cX.js} +1 -1
  94. package/dist/client/assets/{arc-CuT6QA_y.js → arc-CqQdP0Qe.js} +1 -1
  95. package/dist/client/assets/{architectureDiagram-ZHVYKT53-CPXCZ9H4.js → architectureDiagram-ZHVYKT53-89xM7zJD.js} +1 -1
  96. package/dist/client/assets/{banner-DRumuw3F.js → banner-DqJ2pM0Y.js} +1 -1
  97. package/dist/client/assets/{blockDiagram-RJAE7QA3-CM0rka9p.js → blockDiagram-RJAE7QA3-CcxwDmZC.js} +1 -1
  98. package/dist/client/assets/{c4Diagram-XDPPPE54-D4j2cXRy.js → c4Diagram-XDPPPE54-DCIhIyXa.js} +1 -1
  99. package/dist/client/assets/{card-B3CtfC3R.js → card-DT-vFAns.js} +1 -1
  100. package/dist/client/assets/channel-Ngk70nQZ.js +1 -0
  101. package/dist/client/assets/{chunk-2E7WHVMD-KGyqhVpO.js → chunk-2E7WHVMD-BfWEXcCj.js} +1 -1
  102. package/dist/client/assets/{chunk-2Q5K7J3B-Dl0BHoqK.js → chunk-2Q5K7J3B-KLXLZXlR.js} +1 -1
  103. package/dist/client/assets/{chunk-4EMNKR2T-Da7vH6Kv.js → chunk-4EMNKR2T-CL5Gttmj.js} +1 -1
  104. package/dist/client/assets/{chunk-55XCU76K-DgBUEROO.js → chunk-55XCU76K-cfAl84Mv.js} +1 -1
  105. package/dist/client/assets/{chunk-5VM5RSS4-BQ4mn-_I.js → chunk-5VM5RSS4-BqUyGgoH.js} +1 -1
  106. package/dist/client/assets/{chunk-JWPE2WC7-8LPR3mXf.js → chunk-JWPE2WC7-BWr2ST9i.js} +1 -1
  107. package/dist/client/assets/{chunk-VQ5W62QI-BkIVXi4W.js → chunk-VQ5W62QI-V5zYx50O.js} +1 -1
  108. package/dist/client/assets/{chunk-XXDRQBXY-DQXJx06h.js → chunk-XXDRQBXY-gnvheN_J.js} +1 -1
  109. package/dist/client/assets/{chunk-ZCHMQSOR-DzCE7qlD.js → chunk-ZCHMQSOR-ClGxxZvV.js} +2 -2
  110. package/dist/client/assets/{classDiagram-v2-4MYWR3UA-C_cZra7c.js → classDiagram-v2-4MYWR3UA-DvmHzDb5.js} +1 -1
  111. package/dist/client/assets/{command-CDKbyppr.js → command-CNx4L11m.js} +1 -1
  112. package/dist/client/assets/{cose-bilkent-JH36ORCC-DlXHdGwT.js → cose-bilkent-JH36ORCC-Df8nXBRj.js} +1 -1
  113. package/dist/client/assets/{cpu-B7xLO7jn.js → cpu-D8KJEkdh.js} +1 -1
  114. package/dist/client/assets/{cynefin-EF2NZ3EQ-HhP4ArLc.js → cynefin-EF2NZ3EQ-CAn6ufHs.js} +1 -1
  115. package/dist/client/assets/{cynefinDiagram-WF24UDRP-D4GgWnZV.js → cynefinDiagram-WF24UDRP-Cep_NrRw.js} +1 -1
  116. package/dist/client/assets/{dagre-NK4GIZVX-SZ_OI2Zi.js → dagre-NK4GIZVX-sWD3z9wf.js} +1 -1
  117. package/dist/client/assets/{diagram-CBK3MWTC-BN-_Ja5m.js → diagram-CBK3MWTC-CUpaBATr.js} +1 -1
  118. package/dist/client/assets/{diagram-I5XIIV2D-t7AK6xnL.js → diagram-I5XIIV2D-BejWB2ry.js} +1 -1
  119. package/dist/client/assets/{diagram-ODIL2UCW-C1V7szSc.js → diagram-ODIL2UCW-BGKJfNk9.js} +1 -1
  120. package/dist/client/assets/{diagram-PFBEJUXE-DPtraQ2g.js → diagram-PFBEJUXE-V0dP8H8k.js} +1 -1
  121. package/dist/client/assets/{diagram-RJA3I4VV-D2XNRB2b.js → diagram-RJA3I4VV-Bf5dVsFX.js} +1 -1
  122. package/dist/client/assets/{diagram-TYUNFSNR-BieaRy38.js → diagram-TYUNFSNR-CLrMSqb4.js} +1 -1
  123. package/dist/client/assets/{ebnfDiagram-V4P3TTPT-Bwki86UY.js → ebnfDiagram-V4P3TTPT-BGG4CWA0.js} +1 -1
  124. package/dist/client/assets/{elk-QONTBCTQ-WEXSAyHB.js → elk-QONTBCTQ-bf9D6f0w.js} +1 -1
  125. package/dist/client/assets/{empty-state-J-UJ0BUU.js → empty-state-CDoXnrKn.js} +1 -1
  126. package/dist/client/assets/{erDiagram-KYQIGQAA-DIKASnoc.js → erDiagram-KYQIGQAA-fEUv-33P.js} +1 -1
  127. package/dist/client/assets/{execution-config-ILQiJAmy.js → execution-config-Ca9MDOtV.js} +1 -1
  128. package/dist/client/assets/{file-D40js1Zx.js → file-CiyVL55_.js} +1 -1
  129. package/dist/client/assets/{file-exclamation-point-Dg3ZpiAe.js → file-exclamation-point-DaFRIKco.js} +1 -1
  130. package/dist/client/assets/{file-text-DgdvRfMk.js → file-text-DsnD-A8g.js} +1 -1
  131. package/dist/client/assets/{find-latest-widget-fence-D4kBWC_1.js → find-latest-widget-fence-CNsnCgbB.js} +1 -1
  132. package/dist/client/assets/{flowDiagram-IUGLLWBU-CoavNw0M.js → flowDiagram-IUGLLWBU-CRbeSDod.js} +1 -1
  133. package/dist/client/assets/{form-DlPwEgQH.js → form-Cru78aT-.js} +1 -1
  134. package/dist/client/assets/{format-cron-BrK8RzgT.js → format-cron-9K38-tn1.js} +1 -1
  135. package/dist/client/assets/{ganttDiagram-R7GPNTJY-DccKAz7f.js → ganttDiagram-R7GPNTJY-Mkk7zgs_.js} +1 -1
  136. package/dist/client/assets/{git-branch-BpxhecMq.js → git-branch-CONwEYiR.js} +1 -1
  137. package/dist/client/assets/{gitGraphDiagram-PDYL7XHY-DEbo_dgQ.js → gitGraphDiagram-PDYL7XHY-Drre0vyA.js} +1 -1
  138. package/dist/client/assets/{graph-DROgI3M3.js → graph-BJlnKWgo.js} +1 -1
  139. package/dist/client/assets/{heart-c7u4Ezxt.js → heart-CqwUlIUG.js} +1 -1
  140. package/dist/client/assets/{highlighted-body-KPVGNVTW-CrATNdTR.js → highlighted-body-KPVGNVTW-e4LXC_pS.js} +1 -1
  141. package/dist/client/assets/{image-lightbox-DE_fHkw-.js → image-lightbox-DHDtzoja.js} +1 -1
  142. package/dist/client/assets/{image-off-BExgZjfM.js → image-off-DZuLkaRJ.js} +1 -1
  143. package/dist/client/assets/{index-D0eJtRlK.js → index-1yEXEZiH.js} +1 -1
  144. package/dist/client/assets/{index-Be0OJLWK.js → index-A41zxoWk.js} +1 -1
  145. package/dist/client/assets/{index-DeRDq7bD.js → index-B25gvCK_.js} +1 -1
  146. package/dist/client/assets/index-B9bZYNKR.js +1 -0
  147. package/dist/client/assets/{index-DaZ1I8s-.js → index-BBmkfbXd.js} +1 -1
  148. package/dist/client/assets/{index-DNGNMW3c.js → index-BDD2EyoW.js} +1 -1
  149. package/dist/client/assets/{index-Ccf1XBTs.js → index-BFNy-Yp3.js} +1 -1
  150. package/dist/client/assets/{index-DksjixUS.js → index-BIB-maE5.js} +1 -1
  151. package/dist/client/assets/{index-CbHCZsbE.js → index-BKp2B9JS.js} +1 -1
  152. package/dist/client/assets/{index-DCJQGDZk.js → index-BLP5O7X9.js} +1 -1
  153. package/dist/client/assets/{index-DhHobJd3.js → index-BTjZIgFn.js} +1 -1
  154. package/dist/client/assets/{index-BVqSmajJ.js → index-BV2Ezdxv.js} +1 -1
  155. package/dist/client/assets/{index-C7B3eSOP.js → index-B_0LYi32.js} +1 -1
  156. package/dist/client/assets/{index-DDgOoXP1.js → index-Bd7vUYhr.js} +1 -1
  157. package/dist/client/assets/{index-BlyoyIck.js → index-Bo7x9IkO.js} +1 -1
  158. package/dist/client/assets/{index-D150FXCC.js → index-BtDxwJsM.js} +1 -1
  159. package/dist/client/assets/{index-DswGXheF.js → index-By58MgcZ.js} +1 -1
  160. package/dist/client/assets/index-C3cvP8Fo.js +1033 -0
  161. package/dist/client/assets/{index-C5or4L_3.js → index-CVuEUzi5.js} +1 -1
  162. package/dist/client/assets/{index-BkoMsjtM.js → index-CoWJD3Jg.js} +2 -2
  163. package/dist/client/assets/{index-CqPRAM_6.js → index-CyVH876g.js} +1 -1
  164. package/dist/client/assets/{index-BGqvci3k.js → index-D67Kfy-M.js} +1 -1
  165. package/dist/client/assets/{index-D3YeRrne.js → index-DAlpmAIA.js} +1 -1
  166. package/dist/client/assets/{index-BEkYBuOq.js → index-DDNwNOHF.js} +1 -1
  167. package/dist/client/assets/{index-CD8aw6Jb.js → index-DL8ISRMH.js} +1 -1
  168. package/dist/client/assets/{index-AzyLwYS_.js → index-DabU6r9W.js} +3 -3
  169. package/dist/client/assets/{index-CT_pFeX_.js → index-DdJBZE0H.js} +1 -1
  170. package/dist/client/assets/{index-B3eeEDWj.js → index-DijWcSDZ.js} +1 -1
  171. package/dist/client/assets/index-DyRGZyur.css +1 -0
  172. package/dist/client/assets/{index-DINk1YfD.js → index-DzwZJuO1.js} +1 -1
  173. package/dist/client/assets/{index-CZmqtJWZ.js → index-HR8BYVRQ.js} +1 -1
  174. package/dist/client/assets/{index-J3Hh1MnL.js → index-LEcodwyW.js} +1 -1
  175. package/dist/client/assets/index-UPF8suf2.js +1 -0
  176. package/dist/client/assets/{index-DT7pv2iW.js → index-Vz7VUm9l.js} +1 -1
  177. package/dist/client/assets/index-YW-v746p.js +1 -0
  178. package/dist/client/assets/{index-2wezsLA_.js → index-cI2u8WZS.js} +1 -1
  179. package/dist/client/assets/{index-InEBtYxw.js → index-iTQUa_b2.js} +6 -6
  180. package/dist/client/assets/{index-CYy1cjtq.js → index-mZqojApH.js} +1 -1
  181. package/dist/client/assets/{index-dyAahqKe.js → index-pVFjKNjX.js} +1 -1
  182. package/dist/client/assets/{index-DxiRRZRo.js → index-skAhJyIF.js} +1 -1
  183. package/dist/client/assets/{index-BizvylBV.js → index-vJy88bwb.js} +1 -1
  184. package/dist/client/assets/index-wY5OcS4a.js +43 -0
  185. package/dist/client/assets/{index-mwf7ZNk2.js → index-x1yAu9zJ.js} +1 -1
  186. package/dist/client/assets/{index-F-vqXYqa.js → index-xAgihCJ7.js} +1 -1
  187. package/dist/client/assets/{index.esm-BFJ9SG0n.js → index.esm-BUPoRUaG.js} +1 -1
  188. package/dist/client/assets/{infoDiagram-MVDRKAX5-VL8q5pKx.js → infoDiagram-MVDRKAX5-B_Wyzufh.js} +1 -1
  189. package/dist/client/assets/{inline-code-BE9ckzPs.js → inline-code-BIzGDx6z.js} +1 -1
  190. package/dist/client/assets/{ishikawaDiagram-HPEHV2GE-BLKkPYF-.js → ishikawaDiagram-HPEHV2GE-BDk2-6Pd.js} +1 -1
  191. package/dist/client/assets/{journeyDiagram-BOSHW7O7-CSYpRobu.js → journeyDiagram-BOSHW7O7-7qf9KWEQ.js} +1 -1
  192. package/dist/client/assets/{kanban-definition-FNSA4HC5-HilAqtZo.js → kanban-definition-FNSA4HC5-CFYDQmXn.js} +1 -1
  193. package/dist/client/assets/{layers-Cm7coqdo.js → layers-C9tVVcXg.js} +1 -1
  194. package/dist/client/assets/{lightbulb-DqdWS75d.js → lightbulb-f4jtsAh0.js} +1 -1
  195. package/dist/client/assets/{link-2-CDJapTSa.js → link-2-ZNlK1BG1.js} +1 -1
  196. package/dist/client/assets/{list-runtime-types-CP82p1u4.js → list-runtime-types-CqO-QFYD.js} +1 -1
  197. package/dist/client/assets/{markdown-content-m_qereFc.js → markdown-content-DaEVxezf.js} +1 -1
  198. package/dist/client/assets/{mention-pill-DV5HIG5Q.js → mention-pill-BiCPflY-.js} +1 -1
  199. package/dist/client/assets/{mermaid.core-zxW6MBr-.js → mermaid.core-SX8SzrsU.js} +4 -4
  200. package/dist/client/assets/{message-square-off-YVtpbaJ0.js → message-square-off-_qbedNGF.js} +1 -1
  201. package/dist/client/assets/{mindmap-definition-6OY57UG3-IAYemvOg.js → mindmap-definition-6OY57UG3-BloJIArH.js} +1 -1
  202. package/dist/client/assets/{more-details-ReA2ZFBn.js → more-details-CdJT0Ehl.js} +1 -1
  203. package/dist/client/assets/{owner-notice-M4hn_1ep.js → owner-notice-BDafFD_I.js} +1 -1
  204. package/dist/client/assets/{package-CUuTl39E.js → package-Cb7lEm7t.js} +1 -1
  205. package/dist/client/assets/{page-container-BnmNikNZ.js → page-container-DsRgIMAL.js} +1 -1
  206. package/dist/client/assets/{paperclip-C6fYq5Zf.js → paperclip-DNu1VtoX.js} +1 -1
  207. package/dist/client/assets/{path-input-DHn9-XaE.js → path-input-D3O71b-X.js} +1 -1
  208. package/dist/client/assets/{pegDiagram-ECIUJNBX-CojaUwe7.js → pegDiagram-ECIUJNBX-Di48kPNu.js} +1 -1
  209. package/dist/client/assets/{pieDiagram-GNMPY74T-CjP3pw6V.js → pieDiagram-GNMPY74T-DY8B_SPD.js} +1 -1
  210. package/dist/client/assets/{plug-DHQcxt7N.js → plug-IIS_cL9-.js} +1 -1
  211. package/dist/client/assets/{primer-trigger-BmV5wjek.js → primer-trigger-DurKYe8C.js} +2 -2
  212. package/dist/client/assets/{profile-errors-BSCuj3rT.js → profile-errors-BdhZfdvZ.js} +1 -1
  213. package/dist/client/assets/{progress-4FQQfnS6.js → progress-g5kkqvlR.js} +1 -1
  214. package/dist/client/assets/{quadrantDiagram-D57K4MC3-OP0Z8zcR.js → quadrantDiagram-D57K4MC3-Depv_dON.js} +1 -1
  215. package/dist/client/assets/{query-error-state-BkUdxenP.js → query-error-state-PuLGD7Jp.js} +1 -1
  216. package/dist/client/assets/{radio-ta5Bw763.js → radio-QOLZSBz1.js} +1 -1
  217. package/dist/client/assets/{railroadDiagram-Y72NRBL7-CT3NCb9b.js → railroadDiagram-Y72NRBL7-BfD2AiZM.js} +1 -1
  218. package/dist/client/assets/registry-Ck8p6n1T.js +1 -0
  219. package/dist/client/assets/{relay-trace-schemas-DwUuyxao.js → relay-trace-schemas-DF_DfZ7s.js} +1 -1
  220. package/dist/client/assets/{requirementDiagram-EQYSW5RA-tde4lYGp.js → requirementDiagram-EQYSW5RA-B1iTjrkD.js} +1 -1
  221. package/dist/client/assets/{room-files-source-CZWhaaOy.js → room-files-source-g1th8mWs.js} +2 -2
  222. package/dist/client/assets/{rotate-ccw-clock-RfbbgUa4.js → rotate-ccw-clock-BGwYMaGL.js} +1 -1
  223. package/dist/client/assets/{rotate-cw-B3rB_YSw.js → rotate-cw-B4Y0q4GY.js} +1 -1
  224. package/dist/client/assets/{sankeyDiagram-SY24JHO5-sdCzIA7-.js → sankeyDiagram-SY24JHO5-D5TzVJrQ.js} +1 -1
  225. package/dist/client/assets/{scroll-area-B4WB7Q40.js → scroll-area-BvScZKSa.js} +1 -1
  226. package/dist/client/assets/{search-x-DCUmWW2_.js → search-x-CqN5twBj.js} +1 -1
  227. package/dist/client/assets/{sequenceDiagram-BLEHNHQU-DvzTJcKu.js → sequenceDiagram-BLEHNHQU-BhUahaNf.js} +1 -1
  228. package/dist/client/assets/{shield-x-CANziVLc.js → shield-x-DHJrwtKp.js} +1 -1
  229. package/dist/client/assets/signed-in-BmywDpR5.js +1 -0
  230. package/dist/client/assets/{sizeCapture-INFHLROL-DuDA7TKE.js → sizeCapture-INFHLROL-D2Vi1Kq9.js} +1 -1
  231. package/dist/client/assets/{soul-file-Co_8f1qw.js → soul-file-BMpVFN7U.js} +1 -1
  232. package/dist/client/assets/{stateDiagram-v2-A6IESKWZ-BJPX5JTC.js → stateDiagram-v2-A6IESKWZ-b9gSbZnF.js} +1 -1
  233. package/dist/client/assets/{swimlanes-B3ENRKFQ-CiLSffGv.js → swimlanes-B3ENRKFQ-i47jxLY6.js} +1 -1
  234. package/dist/client/assets/swimlanesDiagram-AYQRV4AK-CA9gW19w.js +8 -0
  235. package/dist/client/assets/{table-BSAvOYPp.js → table-CN2HCi4p.js} +1 -1
  236. package/dist/client/assets/{terminal-6CdY-T1V.js → terminal-BORQniao.js} +1 -1
  237. package/dist/client/assets/{timeline-definition-JXYKGLGB-5oq8sl82.js → timeline-definition-JXYKGLGB-eY5gj0js.js} +1 -1
  238. package/dist/client/assets/{trust-posture-D-Yjm6ot.js → trust-posture-Bcyy5Fub.js} +1 -1
  239. package/dist/client/assets/{unplug-Bq_1WdV7.js → unplug-lkD35Rwp.js} +1 -1
  240. package/dist/client/assets/{unverified-catalog-notice-CEzu54YH.js → unverified-catalog-notice-DiCIrrhU.js} +1 -1
  241. package/dist/client/assets/{use-adapter-catalog-Tn3ZbPAj.js → use-adapter-catalog-BrqVd-47.js} +1 -1
  242. package/dist/client/assets/{use-bindings-Bz9YRgO7.js → use-bindings-CU2RSXOy.js} +1 -1
  243. package/dist/client/assets/{use-composer-prefs-D9oKJSQN.js → use-composer-prefs-Dy2oTM8Y.js} +1 -1
  244. package/dist/client/assets/{use-connector-management-CLYFraXN.js → use-connector-management-5oRqzydY.js} +1 -1
  245. package/dist/client/assets/{use-deep-link-scroll-DkS713kG.js → use-deep-link-scroll-Bg5nW8qq.js} +1 -1
  246. package/dist/client/assets/{use-delete-binding-CukKpHBK.js → use-delete-binding-qeyRkvR1.js} +1 -1
  247. package/dist/client/assets/{use-dev-links-DQ32IcGe.js → use-dev-links-FY4J_PjA.js} +1 -1
  248. package/dist/client/assets/{use-external-adapter-catalog-D-FO_XW6.js → use-external-adapter-catalog-HiWFZZrW.js} +1 -1
  249. package/dist/client/assets/{use-full-activity-feed-BNxcyb1j.js → use-full-activity-feed-K1uk9Wya.js} +1 -1
  250. package/dist/client/assets/use-is-below-desktop-Cu_jKnft.js +1 -0
  251. package/dist/client/assets/use-is-hub-BX7ypNRJ.js +1 -0
  252. package/dist/client/assets/{use-jump-back-in-Bibj5tVk.js → use-jump-back-in-BjZ8EswV.js} +1 -1
  253. package/dist/client/assets/{use-local-browser-xg7WXAVK.js → use-local-browser-CTFiF0wf.js} +1 -1
  254. package/dist/client/assets/{use-mesh-topology-BgCSFw8s.js → use-mesh-topology-CafidaIH.js} +1 -1
  255. package/dist/client/assets/{use-mounted-ref-qRbdZfOU.js → use-mounted-ref-B38uSLCx.js} +1 -1
  256. package/dist/client/assets/{use-notification-prefs-B-4kZR7I.js → use-notification-prefs-m9XSNB6W.js} +1 -1
  257. package/dist/client/assets/{use-panel-tab-placements-CCq-mZlY.js → use-panel-tab-placements-D9n6rNJ1.js} +1 -1
  258. package/dist/client/assets/use-pending-read-BoV-UI1E.js +1 -0
  259. package/dist/client/assets/{use-personality-commit-DwSisUfF.js → use-personality-commit-ChLQfLrK.js} +1 -1
  260. package/dist/client/assets/{use-promo-activation-Botoso6l.js → use-promo-activation-DbJDgp4_.js} +1 -1
  261. package/dist/client/assets/{use-promo-dismissals-RJXp-r_J.js → use-promo-dismissals-Csw0j0N0.js} +1 -1
  262. package/dist/client/assets/{use-pulse-freshness-B3390hGg.js → use-pulse-freshness-BIZ7daHW.js} +1 -1
  263. package/dist/client/assets/{use-relay-config-BV0xcLwS.js → use-relay-config-hUB3lVFv.js} +1 -1
  264. package/dist/client/assets/{use-room-follow-claim-Du4hKHIJ.js → use-room-follow-claim-BpKzhniV.js} +1 -1
  265. package/dist/client/assets/{use-roving-tab-list-g2hO6Ruz.js → use-roving-tab-list-BtM0bZL7.js} +1 -1
  266. package/dist/client/assets/{use-session-canvas-i30oMO_Q.js → use-session-canvas-DRrkNRcL.js} +3 -3
  267. package/dist/client/assets/use-session-diagnostics-BTNgouum.js +16 -0
  268. package/dist/client/assets/{use-unclaimed-chats-B92om889.js → use-unclaimed-chats-BbMZtNG9.js} +1 -1
  269. package/dist/client/assets/use-update-config-CkWwKNkY.js +1 -0
  270. package/dist/client/assets/{useMutationState-DdOGdpjP.js → useMutationState-CVpvw27W.js} +1 -1
  271. package/dist/client/assets/{usecaseDiagram-WPOLBNNX-Di5pJvcw.js → usecaseDiagram-WPOLBNNX-CHcpeLg4.js} +1 -1
  272. package/dist/client/assets/{vennDiagram-Q3Y3IDCW-K7KAf26T.js → vennDiagram-Q3Y3IDCW-gQbZL_A6.js} +1 -1
  273. package/dist/client/assets/{wardleyDiagram-IVAIDKWA-DVTaxQt9.js → wardleyDiagram-IVAIDKWA-BFH_WHzZ.js} +1 -1
  274. package/dist/client/assets/{xychartDiagram-4URNHDU4-x-lSJm_B.js → xychartDiagram-4URNHDU4-B0QpyqeZ.js} +1 -1
  275. package/dist/client/index.html +2 -2
  276. package/dist/drizzle/20261019185620_dor3037_wifi_holds.sql +8 -0
  277. package/dist/drizzle/meta/20261019185620_snapshot.json +14079 -0
  278. package/dist/drizzle/meta/_journal.json +7 -0
  279. package/dist/server/extension-child.cjs +18 -2
  280. package/dist/server/index.js +55523 -26605
  281. package/dist/server/index.js.map +2 -2
  282. package/package.json +6 -6
  283. package/dist/client/assets/ApplyToOverridesDialog-CoO6V1G4.js +0 -1
  284. package/dist/client/assets/HandlePage-Cg8H3mQS.js +0 -1
  285. package/dist/client/assets/NamePage-Bx8T98OF.js +0 -1
  286. package/dist/client/assets/PermissionHistory-DzU1rf2B.js +0 -1
  287. package/dist/client/assets/PhotoPage-CmrOIRjf.js +0 -1
  288. package/dist/client/assets/SeenDevices-SPWkdzoK.js +0 -19
  289. package/dist/client/assets/SettingsDialog-_dEXUhHe.js +0 -12
  290. package/dist/client/assets/ToolsPage-Idimrn3o.js +0 -2
  291. package/dist/client/assets/_shell-ClVN2pUj.js +0 -80
  292. package/dist/client/assets/_shell.marketplace-CiL6YRbl.js +0 -1
  293. package/dist/client/assets/_shell.marketplace_.sources-C0sI8e21.js +0 -1
  294. package/dist/client/assets/_shell.session-_hhBvFc6.js +0 -63
  295. package/dist/client/assets/_shell.x._extensionId-BWy5v1YE.js +0 -1
  296. package/dist/client/assets/_shell.x._extensionId_._-BWy5v1YE.js +0 -1
  297. package/dist/client/assets/channel-DjBlTcCV.js +0 -1
  298. package/dist/client/assets/index-7jby-RRg.js +0 -1
  299. package/dist/client/assets/index-BqIHtiaE.js +0 -1
  300. package/dist/client/assets/index-Cga0qx1T.js +0 -1033
  301. package/dist/client/assets/index-Ct4At33X.js +0 -1
  302. package/dist/client/assets/index-DITPwUa9.js +0 -38
  303. package/dist/client/assets/index-DUZrTFYD.css +0 -1
  304. package/dist/client/assets/registry-Dc102rws.js +0 -1
  305. package/dist/client/assets/signed-in-DctJ2IWe.js +0 -1
  306. package/dist/client/assets/swimlanesDiagram-AYQRV4AK-Dv1-QS9J.js +0 -8
  307. package/dist/client/assets/use-is-below-desktop-gTvJDvw4.js +0 -1
  308. package/dist/client/assets/use-is-hub-B1vPpkYU.js +0 -1
  309. package/dist/client/assets/use-pending-read-C8L_v4Zw.js +0 -1
  310. package/dist/client/assets/use-session-diagnostics-a4b83F5J.js +0 -16
  311. package/dist/client/assets/use-update-config-Tbn3SodN.js +0 -1
package/dist/bin/cli.js CHANGED
@@ -729,8 +729,8 @@ function uint8ArrayToBase64(bytes) {
729
729
  }
730
730
  return btoa(binaryString);
731
731
  }
732
- function base64urlToUint8Array(base64url4) {
733
- const base644 = base64url4.replace(/-/g, "+").replace(/_/g, "/");
732
+ function base64urlToUint8Array(base64url5) {
733
+ const base644 = base64url5.replace(/-/g, "+").replace(/_/g, "/");
734
734
  const padding = "=".repeat((4 - base644.length % 4) % 4);
735
735
  return base64ToUint8Array(base644 + padding);
736
736
  }
@@ -22045,7 +22045,19 @@ var init_claude_accounts = __esm({
22045
22045
  * such field, and every reader (`readProjectRootList`) treats that as "any
22046
22046
  * project". The `'0.93.0'` migration still writes `null` onto stored rows.
22047
22047
  */
22048
- onlyProjects: TolerantProjectRootListSchema.optional()
22048
+ onlyProjects: TolerantProjectRootListSchema.optional(),
22049
+ /**
22050
+ * `true` when a person said never to move agents to this account on their
22051
+ * own: a room seat whose account runs out skips it, though a person may
22052
+ * still move a seat to it by naming it. Absent or `false` means it may be
22053
+ * picked, which is how every account behaved before the flag existed.
22054
+ *
22055
+ * Optional rather than defaulted, for the reason `onlyProjects` is: rows are
22056
+ * shared with flow and written by hand, so most carry no such field. A
22057
+ * value that is not a boolean reads as absent rather than failing the
22058
+ * config. The `'0.124.1'` migration sets it on one account.
22059
+ */
22060
+ noAutoMove: external_exports.boolean().optional().catch(void 0)
22049
22061
  });
22050
22062
  ClaudeCodeAccountsSchema = external_exports.preprocess(
22051
22063
  backfillMissingAccountIds,
@@ -26383,6 +26395,11 @@ var init_links = __esm({
26383
26395
  docs: "https://dorkos.ai/docs",
26384
26396
  /** The origin of the DorkOS Cloud `/v1` API, which the website does not serve. */
26385
26397
  cloudApi: "https://cloud.dorkos.ai",
26398
+ /**
26399
+ * The approve page: where an approvals passkey is made and used, and the
26400
+ * relying party it belongs to. Its own origin, never the site's or Cloud's.
26401
+ */
26402
+ approve: "https://approve.dorkos.ai",
26386
26403
  /** The DorkOS app repository, as `owner/repo`. */
26387
26404
  repoSlug: `${GITHUB_ORG}/dorkos`,
26388
26405
  /** The DorkOS app repository on GitHub. */
@@ -26773,7 +26790,7 @@ import path2 from "path";
26773
26790
  import { fileURLToPath } from "url";
26774
26791
  function resolveVersion() {
26775
26792
  if (env2.DORKOS_VERSION_OVERRIDE) return env2.DORKOS_VERSION_OVERRIDE;
26776
- if (true) return "0.124.0";
26793
+ if (true) return "0.124.1";
26777
26794
  const pkgPath = path2.join(path2.dirname(fileURLToPath(import.meta.url)), "../../package.json");
26778
26795
  return JSON.parse(readFileSync(pkgPath, "utf-8")).version;
26779
26796
  }
@@ -39644,9 +39661,9 @@ function preserveWidenedLeaves(skewed, keyPath, next) {
39644
39661
  for (const leaf of skewed) {
39645
39662
  if (leaf.path !== keyPath && !leaf.path.startsWith(`${keyPath}.`)) continue;
39646
39663
  const rest = relativeSegments(keyPath, leaf.path);
39647
- const written = rest.length === 0 ? result2 : valueAt(result2, rest);
39648
- if (written === MISSING) continue;
39649
- if (!isDeepStrictEqual2(written, leaf.used)) continue;
39664
+ const written2 = rest.length === 0 ? result2 : valueAt(result2, rest);
39665
+ if (written2 === MISSING) continue;
39666
+ if (!isDeepStrictEqual2(written2, leaf.used)) continue;
39650
39667
  result2 = rest.length === 0 ? leaf.stored : withPath(result2, rest, leaf.stored);
39651
39668
  }
39652
39669
  return result2;
@@ -40778,10 +40795,31 @@ function raiseEngagedWindowDefaults(store) {
40778
40795
  const posts = store.get("rooms.engagedWindowPosts");
40779
40796
  if (posts === 5 || posts === void 0) store.set("rooms.engagedWindowPosts", 15);
40780
40797
  }
40798
+ function keepAccountOutOfAutoMoves(store) {
40799
+ const runtimes = store.get("runtimes");
40800
+ if (!runtimes || typeof runtimes !== "object" || Array.isArray(runtimes)) return;
40801
+ const block = runtimes.claudeCode;
40802
+ if (!block || typeof block !== "object" || Array.isArray(block)) return;
40803
+ const accounts = block.accounts;
40804
+ if (!Array.isArray(accounts)) return;
40805
+ const index2 = accounts.findIndex(
40806
+ (row2) => !!row2 && typeof row2 === "object" && row2.id === KEPT_FROM_AUTO_MOVES_ACCOUNT_ID
40807
+ );
40808
+ if (index2 === -1 || "noAutoMove" in accounts[index2]) return;
40809
+ const rows = accounts.map(
40810
+ (row2, at) => at === index2 ? { ...row2, noAutoMove: true } : row2
40811
+ );
40812
+ store.set("runtimes", {
40813
+ ...runtimes,
40814
+ claudeCode: { ...block, accounts: rows }
40815
+ });
40816
+ }
40817
+ var KEPT_FROM_AUTO_MOVES_ACCOUNT_ID;
40781
40818
  var init_v0_90_onward = __esm({
40782
40819
  "../../apps/server/src/services/core/config-migrations/v0-90-onward.ts"() {
40783
40820
  "use strict";
40784
40821
  init_config_schema();
40822
+ KEPT_FROM_AUTO_MOVES_ACCOUNT_ID = "claude-ab1";
40785
40823
  }
40786
40824
  });
40787
40825
 
@@ -41476,7 +41514,14 @@ var init_config_migrations = __esm({
41476
41514
  // Writes `runtimes.claudeCode.maxWarmProcesses: null` where the stored
41477
41515
  // section lacks it, and touches nothing else (DOR-3012). See
41478
41516
  // `seedMaxWarmProcesses`.
41479
- "0.123.0": seedMaxWarmProcesses
41517
+ "0.123.0": seedMaxWarmProcesses,
41518
+ // v0.124.0 is the newest tag, and this ships in the 0.124.1 patch, so it
41519
+ // opens 0.124.1. Frozen from merge; anything further opens `'0.125.0'`.
41520
+ //
41521
+ // Sets `noAutoMove: true` on one registered Claude account row that lacks
41522
+ // the field, and touches nothing else (Re-seat P0). See
41523
+ // `keepAccountOutOfAutoMoves`; the history line it owes is written at boot.
41524
+ "0.124.1": keepAccountOutOfAutoMoves
41480
41525
  };
41481
41526
  }
41482
41527
  });
@@ -41540,6 +41585,7 @@ __export(config_manager_exports, {
41540
41585
  dropTunnelPasscodeAndSessionSecret: () => dropTunnelPasscodeAndSessionSecret,
41541
41586
  generalizeTelemetryConsent: () => generalizeTelemetryConsent,
41542
41587
  initConfigManager: () => initConfigManager,
41588
+ keepAccountOutOfAutoMoves: () => keepAccountOutOfAutoMoves,
41543
41589
  migrateClaudeAccountRegistry: () => migrateClaudeAccountRegistry,
41544
41590
  migrateSidebarMembersToItemRefs: () => migrateSidebarMembersToItemRefs,
41545
41591
  migrateSidebarSectionPrefs: () => migrateSidebarSectionPrefs,
@@ -52075,7 +52121,10 @@ function chatModeWord(modeId) {
52075
52121
  if (modeId === null) return "the default";
52076
52122
  return CHAT_MODE_WORD[modeId] ?? modeId;
52077
52123
  }
52078
- var PermissionStateSchema, PermissionAreaIdSchema, PermissionPresetSchema, PermissionActionIdSchema, PermissionOverridesSchema, PermissionStopSchema, AgentPermissionsSchema, PERMISSION_SOURCES, PermissionSourceSchema, PermissionLayerSchema, ResolvedPermissionSchema, PERMISSION_SURFACES, PermissionSurfaceSchema, PermissionAttributionSchema, PermissionChangeTargetSchema, PermissionChangeKeySchema, PermissionChangeSchema, PermissionChangedMetadataSchema, PERMISSION_ANSWERS, PermissionAnsweredMetadataSchema, PermissionSuggestionDismissedMetadataSchema, PermissionSuggestionRestoredMetadataSchema, ALWAYS_SUGGESTION_WINDOW_MS, CHAT_MODE_WORD;
52124
+ function autoMoveWord(value) {
52125
+ return value === KEPT_FROM_AUTO_MOVES ? "Move agents here automatically turned off" : "Move agents here automatically turned on";
52126
+ }
52127
+ var PermissionStateSchema, PermissionAreaIdSchema, PermissionPresetSchema, PermissionActionIdSchema, PermissionOverridesSchema, PermissionStopSchema, AgentPermissionsSchema, PERMISSION_SOURCES, PermissionSourceSchema, PermissionLayerSchema, ResolvedPermissionSchema, PERMISSION_SURFACES, PermissionSurfaceSchema, PermissionAttributionSchema, PermissionChangeTargetSchema, PermissionChangeKeySchema, PermissionChangeSchema, PermissionChangedMetadataSchema, PERMISSION_ANSWERS, PermissionAnsweredMetadataSchema, PermissionSuggestionDismissedMetadataSchema, PermissionSuggestionRestoredMetadataSchema, ALWAYS_SUGGESTION_WINDOW_MS, CHAT_MODE_WORD, KEPT_FROM_AUTO_MOVES;
52079
52128
  var init_permission_schemas = __esm({
52080
52129
  "../shared/src/permissions/permission-schemas.ts"() {
52081
52130
  "use strict";
@@ -52158,7 +52207,20 @@ var init_permission_schemas = __esm({
52158
52207
  * `after` are mode ids). Recorded under the chat's agent; only the one-time
52159
52208
  * raise of existing chats writes it (DOR-3107), and its Undo sets each chat back.
52160
52209
  */
52161
- external_exports.object({ kind: external_exports.literal("chat"), sessionId: external_exports.string() })
52210
+ external_exports.object({ kind: external_exports.literal("chat"), sessionId: external_exports.string() }),
52211
+ /**
52212
+ * Whether one Claude account is kept out of automatic moves (its
52213
+ * `noAutoMove` flag): `before` and `after` are `'on'` (kept out) or `null`
52214
+ * (may be picked). Recorded for everyone, by the upgrade that keeps an
52215
+ * account out and by the Settings switch (`PUT /api/runtimes/claude-code/
52216
+ * accounts/:id/no-auto-move`); its Undo flips the flag back.
52217
+ */
52218
+ external_exports.object({
52219
+ kind: external_exports.literal("account"),
52220
+ accountId: external_exports.string(),
52221
+ /** What the person calls the account, for the history's sentence. */
52222
+ accountName: external_exports.string()
52223
+ })
52162
52224
  ]);
52163
52225
  PermissionChangeSchema = external_exports.object({
52164
52226
  target: PermissionChangeTargetSchema,
@@ -52236,6 +52298,7 @@ var init_permission_schemas = __esm({
52236
52298
  dontAsk: "Never ask",
52237
52299
  bypassPermissions: "Full autonomy"
52238
52300
  };
52301
+ KEPT_FROM_AUTO_MOVES = "on";
52239
52302
  }
52240
52303
  });
52241
52304
 
@@ -53360,7 +53423,7 @@ var init_capabilities = __esm({
53360
53423
  });
53361
53424
 
53362
53425
  // ../shared/src/project-schemas.ts
53363
- var PROJECT_NAME_PATTERN, ProjectRefSchema, ProjectInfoSchema, ProjectListResponseSchema, ProjectResolveQuerySchema, ProjectResolveResponseSchema, AccountEligibilityRowSchema, AccountEligibilityQuerySchema, AccountEligibilityResponseSchema, ProjectAccountsRequestSchema, ProjectWithoutCreditsRequestSchema, OnlyProjectsRequestSchema, OnlyProjectsResponseSchema;
53426
+ var PROJECT_NAME_PATTERN, ProjectRefSchema, ProjectInfoSchema, ProjectListResponseSchema, ProjectResolveQuerySchema, ProjectResolveResponseSchema, AccountEligibilityRowSchema, AccountEligibilityQuerySchema, AccountEligibilityResponseSchema, ProjectAccountsRequestSchema, ProjectWithoutCreditsRequestSchema, OnlyProjectsRequestSchema, OnlyProjectsResponseSchema, NoAutoMoveSchema;
53364
53427
  var init_project_schemas = __esm({
53365
53428
  "../shared/src/project-schemas.ts"() {
53366
53429
  "use strict";
@@ -53467,6 +53530,10 @@ var init_project_schemas = __esm({
53467
53530
  /** The projects the account is now kept to, or null for any project. */
53468
53531
  onlyProjects: external_exports.array(ProjectRefSchema).nullable()
53469
53532
  }).openapi("OnlyProjectsResponse");
53533
+ NoAutoMoveSchema = external_exports.object({
53534
+ /** `true` to keep agents off the account in automatic moves, `false` to allow them. */
53535
+ noAutoMove: external_exports.boolean()
53536
+ }).openapi("NoAutoMove");
53470
53537
  }
53471
53538
  });
53472
53539
 
@@ -53747,7 +53814,6 @@ var init_account_usage_codex = __esm({
53747
53814
  var LEDGER_RUNTIMES, LEDGER_SOURCES, RateLimitStatusSchema, ISO_TIME_PATTERN, IsoTimeSchema, LedgerSourceSchema, LedgerEntrySchema, WINDOW_KEY_PATTERN, LedgerPlanSchema, LedgerCreditsSchema, LedgerSpendSchema, UsageLedgerSchema, MINUTE_MS, HOUR_MS, FIVE_HOUR_MS, SEVEN_DAY_MS, MAX_FUTURE_SKEW_MS, AccountUsageSchema, LimitResolutionSchema, LimitHistoryEntrySchema, LimitHistoryResponseSchema, FoundClaudeFolderSchema, DismissFoundFolderRequestSchema;
53748
53815
  var init_account_usage = __esm({
53749
53816
  "../shared/src/account-usage.ts"() {
53750
- "use strict";
53751
53817
  init_zod();
53752
53818
  init_zod_openapi();
53753
53819
  init_ledger_slug();
@@ -56534,6 +56600,9 @@ var init_schemas4 = __esm({
56534
56600
  }),
56535
56601
  onlyProjects: external_exports.array(ProjectRefSchema).nullable().optional().openapi({
56536
56602
  description: 'The projects this account may work in ("Only for client-app"), or null for any project (spec flow-multiproject \xA78). Change it with PUT /api/runtimes/claude-code/accounts/:id/only-projects, never by writing it back through PATCH /api/config. Absent on a server too old to report it'
56603
+ }),
56604
+ noAutoMove: external_exports.boolean().optional().openapi({
56605
+ description: "True when DorkOS never moves a room agent to this account on its own (a person still may). Absent otherwise, and on a server too old to report it. Change it with PUT /api/runtimes/claude-code/accounts/:id/no-auto-move"
56537
56606
  })
56538
56607
  })
56539
56608
  ).openapi({ description: "The Claude accounts the operator has registered" }),
@@ -62951,9 +63020,9 @@ var init_is_api_error = __esm({
62951
63020
  }
62952
63021
  });
62953
63022
 
62954
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/is-api-error.mjs
63023
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/is-api-error.mjs
62955
63024
  var init_is_api_error2 = __esm({
62956
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/is-api-error.mjs"() {
63025
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/is-api-error.mjs"() {
62957
63026
  init_is_api_error();
62958
63027
  }
62959
63028
  });
@@ -63105,7 +63174,7 @@ var init_api2 = __esm({
63105
63174
  }
63106
63175
  });
63107
63176
 
63108
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/wildcard.mjs
63177
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/wildcard.mjs
63109
63178
  function escapeRegExpChar(char) {
63110
63179
  if (char === "-" || char === "^" || char === "$" || char === "+" || char === "." || char === "(" || char === ")" || char === "|" || char === "[" || char === "]" || char === "{" || char === "}" || char === "*" || char === "?" || char === "\\") return `\\${char}`;
63111
63180
  else return char;
@@ -63185,7 +63254,7 @@ function wildcardMatch(pattern, options) {
63185
63254
  return fn;
63186
63255
  }
63187
63256
  var init_wildcard = __esm({
63188
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/wildcard.mjs"() {
63257
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/wildcard.mjs"() {
63189
63258
  }
63190
63259
  });
63191
63260
 
@@ -63464,7 +63533,7 @@ var init_env3 = __esm({
63464
63533
  }
63465
63534
  });
63466
63535
 
63467
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/url.mjs
63536
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/url.mjs
63468
63537
  function isLoopbackForDevScheme(host) {
63469
63538
  const hostname4 = host.replace(/:\d+$/, "").replace(/^\[|\]$/g, "").toLowerCase();
63470
63539
  return hostname4 === "localhost" || hostname4.endsWith(".localhost") || hostname4 === "::1" || hostname4.startsWith("127.");
@@ -63621,7 +63690,7 @@ function resolveBaseURL(config3, basePath, source, loadEnv, trustedProxyHeaders)
63621
63690
  }
63622
63691
  var SLASH_CHAR_CODE, matchesHostPattern;
63623
63692
  var init_url = __esm({
63624
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/url.mjs"() {
63693
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/url.mjs"() {
63625
63694
  init_wildcard();
63626
63695
  init_env3();
63627
63696
  init_error2();
@@ -63636,10 +63705,10 @@ var init_url = __esm({
63636
63705
  }
63637
63706
  });
63638
63707
 
63639
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/auth/trusted-origins.mjs
63708
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/auth/trusted-origins.mjs
63640
63709
  var CONTROL_CHARACTER_PATTERN, RELATIVE_URL_PARSER_ORIGIN, ENCODED_PATH_SEPARATOR_PATTERN, normalizePath3, parseCustomSchemeOrigin, isSafeRelativeURL, matchesOriginPattern;
63641
63710
  var init_trusted_origins = __esm({
63642
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/auth/trusted-origins.mjs"() {
63711
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/auth/trusted-origins.mjs"() {
63643
63712
  init_wildcard();
63644
63713
  init_url();
63645
63714
  CONTROL_CHARACTER_PATTERN = /[\u0000-\u001f\u007f-\u009f]/;
@@ -63761,7 +63830,7 @@ var init_deprecate = __esm({
63761
63830
  }
63762
63831
  });
63763
63832
 
63764
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/middlewares/origin-check.mjs
63833
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/middlewares/origin-check.mjs
63765
63834
  function shouldSkipCSRFForBackwardCompat(ctx) {
63766
63835
  return ctx.context.skipOriginCheck === true && ctx.context.options.advanced?.disableCSRFCheck === void 0;
63767
63836
  }
@@ -63828,7 +63897,7 @@ async function validateFormCsrf(ctx) {
63828
63897
  }
63829
63898
  var logBackwardCompatWarning, originCheckMiddleware, originCheck, formCsrfMiddleware;
63830
63899
  var init_origin_check = __esm({
63831
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/middlewares/origin-check.mjs"() {
63900
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/middlewares/origin-check.mjs"() {
63832
63901
  init_url();
63833
63902
  init_trusted_origins();
63834
63903
  init_error2();
@@ -64061,7 +64130,7 @@ var init_ip = __esm({
64061
64130
  }
64062
64131
  });
64063
64132
 
64064
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/rate-limiter/index.mjs
64133
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/rate-limiter/index.mjs
64065
64134
  function pruneMemoryStore() {
64066
64135
  const now3 = Date.now();
64067
64136
  for (const [key, entry] of memory) if (now3 >= entry.expiresAt) memory.delete(key);
@@ -64126,10 +64195,10 @@ function getRetryAfter(lastRequest, window2) {
64126
64195
  }
64127
64196
  function createDatabaseStorageWrapper(ctx) {
64128
64197
  const model = "rateLimit";
64129
- const db = ctx.adapter;
64198
+ const db2 = ctx.adapter;
64130
64199
  let longestObservedWindow = Math.max(...getConfiguredRateLimitWindows(ctx));
64131
64200
  const readRow = async (key) => {
64132
- const data = (await db.findMany({
64201
+ const data = (await db2.findMany({
64133
64202
  model,
64134
64203
  where: [{
64135
64204
  field: "key",
@@ -64145,7 +64214,7 @@ function createDatabaseStorageWrapper(ctx) {
64145
64214
  const data = await readRow(key);
64146
64215
  const now3 = Date.now();
64147
64216
  if (!data) try {
64148
- await db.create({
64217
+ await db2.create({
64149
64218
  model,
64150
64219
  data: {
64151
64220
  key,
@@ -64162,7 +64231,7 @@ function createDatabaseStorageWrapper(ctx) {
64162
64231
  return consume(key, rule);
64163
64232
  }
64164
64233
  if (now3 - data.lastRequest >= windowInMs) {
64165
- if (await db.incrementOne({
64234
+ if (await db2.incrementOne({
64166
64235
  model,
64167
64236
  where: [{
64168
64237
  field: "key",
@@ -64187,7 +64256,7 @@ function createDatabaseStorageWrapper(ctx) {
64187
64256
  return consume(key, rule);
64188
64257
  }
64189
64258
  const windowStart = now3 - windowInMs;
64190
- if (await db.incrementOne({
64259
+ if (await db2.incrementOne({
64191
64260
  model,
64192
64261
  where: [
64193
64262
  {
@@ -64221,7 +64290,7 @@ function createDatabaseStorageWrapper(ctx) {
64221
64290
  };
64222
64291
  const deleteExpiredRows = async (now3) => {
64223
64292
  const cutoff = now3 - longestObservedWindow * 1e3;
64224
- await ctx.runInBackgroundOrAwait(db.deleteMany({
64293
+ await ctx.runInBackgroundOrAwait(db2.deleteMany({
64225
64294
  model,
64226
64295
  where: [{
64227
64296
  field: "lastRequest",
@@ -64359,7 +64428,7 @@ function getDefaultSpecialRules() {
64359
64428
  }
64360
64429
  var memory, MEMORY_STORE_MAX_ENTRIES, ipWarningLogged, NO_TRUSTED_IP_KEY;
64361
64430
  var init_rate_limiter = __esm({
64362
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/rate-limiter/index.mjs"() {
64431
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/rate-limiter/index.mjs"() {
64363
64432
  init_wildcard();
64364
64433
  init_error2();
64365
64434
  init_ip();
@@ -64907,14 +64976,14 @@ function diffSchema(expected, actual) {
64907
64976
  });
64908
64977
  continue;
64909
64978
  }
64910
- const written = /* @__PURE__ */ new Set([table2.idColumn ?? "id", ...Object.keys(table2.fields)]);
64911
- for (const column of written) if (!actualTable.columns.some((candidate) => candidate.name === column)) findings.push({
64979
+ const written2 = /* @__PURE__ */ new Set([table2.idColumn ?? "id", ...Object.keys(table2.fields)]);
64980
+ for (const column of written2) if (!actualTable.columns.some((candidate) => candidate.name === column)) findings.push({
64912
64981
  kind: "missing-column",
64913
64982
  table: tableName,
64914
64983
  column
64915
64984
  });
64916
64985
  for (const column of actualTable.columns) {
64917
- if (written.has(column.name) || column.nullable || column.hasDefault) continue;
64986
+ if (written2.has(column.name) || column.nullable || column.hasDefault) continue;
64918
64987
  findings.push({
64919
64988
  kind: "unexpected-required-column",
64920
64989
  table: tableName,
@@ -65192,26 +65261,26 @@ var init_context2 = __esm({
65192
65261
  }
65193
65262
  });
65194
65263
 
65195
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/state/oauth.mjs
65264
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/state/oauth.mjs
65196
65265
  var getRawOAuthState, setOAuthState, getOAuthServerContext, setOAuthServerContext;
65197
65266
  var init_oauth = __esm({
65198
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/state/oauth.mjs"() {
65267
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/state/oauth.mjs"() {
65199
65268
  init_context2();
65200
65269
  ({ get: getRawOAuthState, set: setOAuthState } = defineRequestState(() => null));
65201
65270
  ({ get: getOAuthServerContext, set: setOAuthServerContext } = defineRequestState(() => null));
65202
65271
  }
65203
65272
  });
65204
65273
 
65205
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/state/should-session-refresh.mjs
65274
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/state/should-session-refresh.mjs
65206
65275
  var getShouldSkipSessionRefresh, setShouldSkipSessionRefresh;
65207
65276
  var init_should_session_refresh = __esm({
65208
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/state/should-session-refresh.mjs"() {
65277
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/state/should-session-refresh.mjs"() {
65209
65278
  init_context2();
65210
65279
  ({ get: getShouldSkipSessionRefresh, set: setShouldSkipSessionRefresh } = defineRequestState(() => false));
65211
65280
  }
65212
65281
  });
65213
65282
 
65214
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/context/store-capabilities.mjs
65283
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/context/store-capabilities.mjs
65215
65284
  function hasServerSessionStore(options) {
65216
65285
  return !!options.database || !!options.secondaryStorage;
65217
65286
  }
@@ -65222,7 +65291,7 @@ function shouldBindAccountCookieToSessionUser(options) {
65222
65291
  return hasServerAccountStore(options);
65223
65292
  }
65224
65293
  var init_store_capabilities = __esm({
65225
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/context/store-capabilities.mjs"() {
65294
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/context/store-capabilities.mjs"() {
65226
65295
  }
65227
65296
  });
65228
65297
 
@@ -65379,7 +65448,7 @@ var init_db2 = __esm({
65379
65448
  }
65380
65449
  });
65381
65450
 
65382
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/schema.mjs
65451
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/schema.mjs
65383
65452
  function getFields(options, modelName, mode) {
65384
65453
  const cacheKey = `${modelName}:${mode}`;
65385
65454
  if (!cache.has(options)) cache.set(options, /* @__PURE__ */ new Map());
@@ -65524,7 +65593,7 @@ function mergeSchema(schema3, newSchema) {
65524
65593
  }
65525
65594
  var cache;
65526
65595
  var init_schema2 = __esm({
65527
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/schema.mjs"() {
65596
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/schema.mjs"() {
65528
65597
  init_db();
65529
65598
  init_error2();
65530
65599
  init_db2();
@@ -65532,10 +65601,10 @@ var init_schema2 = __esm({
65532
65601
  }
65533
65602
  });
65534
65603
 
65535
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/date.mjs
65604
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/date.mjs
65536
65605
  var getDate;
65537
65606
  var init_date = __esm({
65538
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/date.mjs"() {
65607
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/date.mjs"() {
65539
65608
  getDate = (span, unit = "ms") => {
65540
65609
  return new Date(Date.now() + (unit === "sec" ? span * 1e3 : span));
65541
65610
  };
@@ -68069,7 +68138,7 @@ var init_webapi = __esm({
68069
68138
  }
68070
68139
  });
68071
68140
 
68072
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/crypto/jwt.mjs
68141
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/crypto/jwt.mjs
68073
68142
  async function signJWT(payload, secret, expiresIn = 3600) {
68074
68143
  return await new SignJWT(payload).setProtectedHeader({ alg: "HS256" }).setIssuedAt().setExpirationTime(Math.floor(Date.now() / 1e3) + expiresIn).sign(new TextEncoder().encode(secret));
68075
68144
  }
@@ -68159,7 +68228,7 @@ async function symmetricDecodeJWT(token, secret, salt) {
68159
68228
  }
68160
68229
  var info, now, alg, enc, jwtDecryptOpts;
68161
68230
  var init_jwt = __esm({
68162
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/crypto/jwt.mjs"() {
68231
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/crypto/jwt.mjs"() {
68163
68232
  init_hkdf();
68164
68233
  init_sha2();
68165
68234
  init_webapi();
@@ -68214,7 +68283,7 @@ var init_jwt = __esm({
68214
68283
  }
68215
68284
  });
68216
68285
 
68217
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/cookies/cookie-utils.mjs
68286
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/cookies/cookie-utils.mjs
68218
68287
  function tryDecode2(str2) {
68219
68288
  if (str2.indexOf("%") === -1) return str2;
68220
68289
  try {
@@ -68281,7 +68350,7 @@ function parseCookies2(cookie) {
68281
68350
  }
68282
68351
  var SECURE_COOKIE_PREFIX, cookieNameRegex, cookieValueRegex;
68283
68352
  var init_cookie_utils = __esm({
68284
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/cookies/cookie-utils.mjs"() {
68353
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/cookies/cookie-utils.mjs"() {
68285
68354
  SECURE_COOKIE_PREFIX = "__Secure-";
68286
68355
  cookieNameRegex = /^[\x21\x23-\x27\x2A\x2B\x2D\x2E\x30-\x39\x41-\x5A\x5E\x5F\x60\x61-\x7A\x7C\x7E]+$/;
68287
68356
  cookieValueRegex = /^[\x20\x21\x23-\x3A\x3C-\x5B\x5D-\x7E]*$/;
@@ -68328,7 +68397,7 @@ var init_json = __esm({
68328
68397
  }
68329
68398
  });
68330
68399
 
68331
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/cookies/session-store.mjs
68400
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/cookies/session-store.mjs
68332
68401
  function getMaxCookieValueSize(name2, options) {
68333
68402
  return MAX_COOKIE_SIZE - serializeCookie(name2, "", { ...options }).length;
68334
68403
  }
@@ -68432,7 +68501,7 @@ async function getAccountCookie(c3) {
68432
68501
  }
68433
68502
  var MAX_COOKIE_SIZE, MAX_COOKIE_CHUNKS, storeFactory, createSessionStore, createAccountStore, getSessionQuerySchema;
68434
68503
  var init_session_store = __esm({
68435
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/cookies/session-store.mjs"() {
68504
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/cookies/session-store.mjs"() {
68436
68505
  init_jwt();
68437
68506
  init_cookie_utils();
68438
68507
  init_json();
@@ -68483,16 +68552,16 @@ var init_session_store = __esm({
68483
68552
  }
68484
68553
  });
68485
68554
 
68486
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/is-promise.mjs
68555
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/is-promise.mjs
68487
68556
  function isPromise(obj) {
68488
68557
  return !!obj && (typeof obj === "object" || typeof obj === "function") && typeof obj.then === "function";
68489
68558
  }
68490
68559
  var init_is_promise = __esm({
68491
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/is-promise.mjs"() {
68560
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/is-promise.mjs"() {
68492
68561
  }
68493
68562
  });
68494
68563
 
68495
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/time.mjs
68564
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/time.mjs
68496
68565
  function parse3(value) {
68497
68566
  const match = REGEX2.exec(value);
68498
68567
  if (!match || match[4] && match[1]) throw new TypeError(`Invalid time string format: "${value}". Use formats like "7d", "30m", "1 hour", etc.`);
@@ -68554,7 +68623,7 @@ function sec(value) {
68554
68623
  }
68555
68624
  var SEC, MIN, HOUR, DAY, WEEK, MONTH, YEAR, REGEX2;
68556
68625
  var init_time = __esm({
68557
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/time.mjs"() {
68626
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/time.mjs"() {
68558
68627
  SEC = 1e3;
68559
68628
  MIN = SEC * 60;
68560
68629
  HOUR = MIN * 60;
@@ -68566,7 +68635,7 @@ var init_time = __esm({
68566
68635
  }
68567
68636
  });
68568
68637
 
68569
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/cookies/cache.mjs
68638
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/cookies/cache.mjs
68570
68639
  function parseCookieCachePayload(value) {
68571
68640
  const parsed = safeJSONParse(value);
68572
68641
  if (parsed === null) return null;
@@ -68584,7 +68653,7 @@ function parseCompactCookieCache(value) {
68584
68653
  }
68585
68654
  var cookieCachePayloadSchema, compactCookieCacheSchema;
68586
68655
  var init_cache = __esm({
68587
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/cookies/cache.mjs"() {
68656
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/cookies/cache.mjs"() {
68588
68657
  init_db();
68589
68658
  init_env3();
68590
68659
  init_json();
@@ -68765,7 +68834,7 @@ var init_hmac2 = __esm({
68765
68834
  }
68766
68835
  });
68767
68836
 
68768
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/cookies/index.mjs
68837
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/cookies/index.mjs
68769
68838
  function createCookieGetter(options) {
68770
68839
  const baseURLString = typeof options.baseURL === "string" ? options.baseURL : void 0;
68771
68840
  const dynamicProtocol = typeof options.baseURL === "object" && options.baseURL !== null ? options.baseURL.protocol : void 0;
@@ -68976,7 +69045,7 @@ function deleteSessionCookie(ctx, skipDontRememberMe) {
68976
69045
  if (!skipDontRememberMe) expireCookie(ctx, ctx.context.authCookies.dontRememberToken);
68977
69046
  }
68978
69047
  var init_cookies2 = __esm({
68979
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/cookies/index.mjs"() {
69048
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/cookies/index.mjs"() {
68980
69049
  init_url();
68981
69050
  init_store_capabilities();
68982
69051
  init_jwt();
@@ -68997,10 +69066,10 @@ var init_cookies2 = __esm({
68997
69066
  }
68998
69067
  });
68999
69068
 
69000
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/session.mjs
69069
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/session.mjs
69001
69070
  var getSession, isStateful, getSessionFromCtx, getAuthoritativeSessionFromCtx, sessionMiddleware, sensitiveSessionMiddleware, requestOnlySessionMiddleware, freshSessionMiddleware, listSessions, revokeSession, revokeSessions, revokeOtherSessions;
69002
69071
  var init_session2 = __esm({
69003
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/session.mjs"() {
69072
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/session.mjs"() {
69004
69073
  init_is_api_error2();
69005
69074
  init_store_capabilities();
69006
69075
  init_schema2();
@@ -69420,7 +69489,7 @@ var init_session2 = __esm({
69420
69489
  }
69421
69490
  });
69422
69491
 
69423
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/validate-user-info.mjs
69492
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/validate-user-info.mjs
69424
69493
  function assertValidUserInfoSource(source) {
69425
69494
  if (!source?.method) throw new APIError2("FORBIDDEN", {
69426
69495
  code: "validation_source_missing",
@@ -69455,7 +69524,7 @@ async function assertValidUserInfo(ctx, data) {
69455
69524
  });
69456
69525
  }
69457
69526
  var init_validate_user_info = __esm({
69458
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/validate-user-info.mjs"() {
69527
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/validate-user-info.mjs"() {
69459
69528
  init_error2();
69460
69529
  }
69461
69530
  });
@@ -69481,7 +69550,7 @@ var init_hash = __esm({
69481
69550
  }
69482
69551
  });
69483
69552
 
69484
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/verification-token-storage.mjs
69553
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/verification-token-storage.mjs
69485
69554
  async function processIdentifier(identifier, option) {
69486
69555
  if (!option || option === "plain") return identifier;
69487
69556
  if (option === "hashed") return defaultKeyHasher(identifier);
@@ -69500,7 +69569,7 @@ function getStorageOption(identifier, config3) {
69500
69569
  }
69501
69570
  var defaultKeyHasher;
69502
69571
  var init_verification_token_storage = __esm({
69503
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/verification-token-storage.mjs"() {
69572
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/verification-token-storage.mjs"() {
69504
69573
  init_base64();
69505
69574
  init_hash();
69506
69575
  defaultKeyHasher = async (identifier) => {
@@ -71255,7 +71324,7 @@ var init_instrumentation = __esm({
71255
71324
  }
71256
71325
  });
71257
71326
 
71258
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/with-hooks.mjs
71327
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/with-hooks.mjs
71259
71328
  function getWithHooks(adapter, ctx) {
71260
71329
  const withSpan3 = createWithSpan(ctx.options);
71261
71330
  const hooksEntries = ctx.hooks;
@@ -71494,7 +71563,7 @@ function getWithHooks(adapter, ctx) {
71494
71563
  };
71495
71564
  }
71496
71565
  var init_with_hooks = __esm({
71497
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/with-hooks.mjs"() {
71566
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/with-hooks.mjs"() {
71498
71567
  init_context2();
71499
71568
  init_instrumentation();
71500
71569
  }
@@ -71560,14 +71629,14 @@ var init_id2 = __esm({
71560
71629
  }
71561
71630
  });
71562
71631
 
71563
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/internal-adapter.mjs
71632
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/internal-adapter.mjs
71564
71633
  function getTTLSeconds(expiresAt, now3 = Date.now()) {
71565
71634
  const expiresMs = typeof expiresAt === "number" ? expiresAt : expiresAt.getTime();
71566
71635
  return Math.max(Math.floor((expiresMs - now3) / 1e3), 0);
71567
71636
  }
71568
71637
  var createInternalAdapter;
71569
71638
  var init_internal_adapter = __esm({
71570
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/internal-adapter.mjs"() {
71639
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/internal-adapter.mjs"() {
71571
71640
  init_schema2();
71572
71641
  init_date();
71573
71642
  init_validate_user_info();
@@ -72733,7 +72802,7 @@ var init_host = __esm({
72733
72802
  }
72734
72803
  });
72735
72804
 
72736
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/context/helpers.mjs
72805
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/context/helpers.mjs
72737
72806
  async function runPluginInit(context2) {
72738
72807
  let options = context2.options;
72739
72808
  const plugins = options.plugins || [];
@@ -72865,7 +72934,7 @@ async function getTrustedProviders(options, request) {
72865
72934
  return (await trustedProviders(request) ?? []).filter((v2) => Boolean(v2));
72866
72935
  }
72867
72936
  var init_helpers = __esm({
72868
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/context/helpers.mjs"() {
72937
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/context/helpers.mjs"() {
72869
72938
  init_url();
72870
72939
  init_is_promise();
72871
72940
  init_cookies2();
@@ -72877,7 +72946,7 @@ var init_helpers = __esm({
72877
72946
  }
72878
72947
  });
72879
72948
 
72880
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/oauth2/account-key.mjs
72949
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/oauth2/account-key.mjs
72881
72950
  function toOAuthProfileRecord(profile) {
72882
72951
  return profile;
72883
72952
  }
@@ -72903,12 +72972,12 @@ async function resolveOAuthAccountKeyForAPI(provider, tokens, profile) {
72903
72972
  }
72904
72973
  }
72905
72974
  var init_account_key = __esm({
72906
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/oauth2/account-key.mjs"() {
72975
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/oauth2/account-key.mjs"() {
72907
72976
  init_error2();
72908
72977
  }
72909
72978
  });
72910
72979
 
72911
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/oauth2/errors.mjs
72980
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/oauth2/errors.mjs
72912
72981
  function redirectOnError(ctx, errorURL, error63, description) {
72913
72982
  const params = new URLSearchParams({ error: error63 });
72914
72983
  if (description) params.set("error_description", description);
@@ -72920,7 +72989,7 @@ function missingEmailLogMessage(providerId, options) {
72920
72989
  }
72921
72990
  var OAUTH_CALLBACK_ERROR_CODES, HANDLING_DOCS_URL;
72922
72991
  var init_errors4 = __esm({
72923
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/oauth2/errors.mjs"() {
72992
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/oauth2/errors.mjs"() {
72924
72993
  init_url2();
72925
72994
  OAUTH_CALLBACK_ERROR_CODES = {
72926
72995
  NO_CODE: "no_code",
@@ -72977,10 +73046,10 @@ var init_password_node = __esm({
72977
73046
  }
72978
73047
  });
72979
73048
 
72980
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/crypto/password.mjs
73049
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/crypto/password.mjs
72981
73050
  var hashPassword$1, verifyPassword$1;
72982
73051
  var init_password = __esm({
72983
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/crypto/password.mjs"() {
73052
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/crypto/password.mjs"() {
72984
73053
  init_password_node();
72985
73054
  hashPassword$1 = hashPassword;
72986
73055
  verifyPassword$1 = async ({ hash: hash3, password }) => {
@@ -72989,10 +73058,10 @@ var init_password = __esm({
72989
73058
  }
72990
73059
  });
72991
73060
 
72992
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/crypto/random.mjs
73061
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/crypto/random.mjs
72993
73062
  var generateRandomString;
72994
73063
  var init_random2 = __esm({
72995
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/crypto/random.mjs"() {
73064
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/crypto/random.mjs"() {
72996
73065
  init_random();
72997
73066
  generateRandomString = createRandomStringGenerator("a-z", "0-9", "A-Z", "-_");
72998
73067
  }
@@ -73905,7 +73974,7 @@ var init_chacha = __esm({
73905
73974
  }
73906
73975
  });
73907
73976
 
73908
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/crypto/index.mjs
73977
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/crypto/index.mjs
73909
73978
  function parseEnvelope(data) {
73910
73979
  if (!data.startsWith(ENVELOPE_PREFIX)) return null;
73911
73980
  const firstSep = 4;
@@ -73934,7 +74003,7 @@ async function rawDecrypt(secret, hex4) {
73934
74003
  }
73935
74004
  var ENVELOPE_PREFIX, symmetricEncrypt, symmetricDecrypt;
73936
74005
  var init_crypto2 = __esm({
73937
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/crypto/index.mjs"() {
74006
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/crypto/index.mjs"() {
73938
74007
  init_random2();
73939
74008
  init_dist5();
73940
74009
  init_hash();
@@ -73962,7 +74031,7 @@ var init_crypto2 = __esm({
73962
74031
  }
73963
74032
  });
73964
74033
 
73965
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/oauth2/utils.mjs
74034
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/oauth2/utils.mjs
73966
74035
  function isLikelyEncrypted(token) {
73967
74036
  if (token.startsWith("$ba$")) return true;
73968
74037
  return token.length % 2 === 0 && /^[0-9a-f]+$/i.test(token);
@@ -73990,12 +74059,12 @@ function getOAuthCallbackPath(provider) {
73990
74059
  return provider.callbackPath.startsWith("/") ? provider.callbackPath : `/${provider.callbackPath}`;
73991
74060
  }
73992
74061
  var init_utils6 = __esm({
73993
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/oauth2/utils.mjs"() {
74062
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/oauth2/utils.mjs"() {
73994
74063
  init_crypto2();
73995
74064
  }
73996
74065
  });
73997
74066
 
73998
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/request.mjs
74067
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/request.mjs
73999
74068
  function safeCloneRequest(request) {
74000
74069
  if (!request) return;
74001
74070
  try {
@@ -74017,11 +74086,11 @@ function safeCloneRequest(request) {
74017
74086
  }
74018
74087
  }
74019
74088
  var init_request = __esm({
74020
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/request.mjs"() {
74089
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/request.mjs"() {
74021
74090
  }
74022
74091
  });
74023
74092
 
74024
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/email-verification.mjs
74093
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/email-verification.mjs
74025
74094
  async function createEmailVerificationToken(secret, email3, updateTo, expiresIn = 3600, extraPayload) {
74026
74095
  return await signJWT({
74027
74096
  email: email3.toLowerCase(),
@@ -74045,7 +74114,7 @@ async function sendVerificationEmailFn(ctx, user2) {
74045
74114
  }
74046
74115
  var sendVerificationEmail, verifyEmail;
74047
74116
  var init_email_verification = __esm({
74048
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/email-verification.mjs"() {
74117
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/email-verification.mjs"() {
74049
74118
  init_origin_check();
74050
74119
  init_jwt();
74051
74120
  init_schema2();
@@ -75282,7 +75351,7 @@ var init_oauth2 = __esm({
75282
75351
  }
75283
75352
  });
75284
75353
 
75285
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/oauth2/link-account.mjs
75354
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/oauth2/link-account.mjs
75286
75355
  function linkOAuthAccountFailure(code, message2) {
75287
75356
  return {
75288
75357
  linked: false,
@@ -75642,7 +75711,7 @@ async function applyUpdateUserInfoOnLink(c3, userId, userInfo) {
75642
75711
  }
75643
75712
  }
75644
75713
  var init_link_account = __esm({
75645
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/oauth2/link-account.mjs"() {
75714
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/oauth2/link-account.mjs"() {
75646
75715
  init_is_api_error2();
75647
75716
  init_schema2();
75648
75717
  init_session_store();
@@ -75657,7 +75726,7 @@ var init_link_account = __esm({
75657
75726
  }
75658
75727
  });
75659
75728
 
75660
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/state.mjs
75729
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/state.mjs
75661
75730
  async function generateGenericState(c3, stateData, settings) {
75662
75731
  const state = generateRandomString(32);
75663
75732
  if (c3.context.oauthConfig.storeStateStrategy === "cookie") {
@@ -75754,7 +75823,7 @@ async function parseGenericState(c3, state, settings) {
75754
75823
  }
75755
75824
  var stateDataSchema, INTERNAL_STATE_KEYS, StateError;
75756
75825
  var init_state = __esm({
75757
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/state.mjs"() {
75826
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/state.mjs"() {
75758
75827
  init_random2();
75759
75828
  init_crypto2();
75760
75829
  init_cookies2();
@@ -75810,7 +75879,7 @@ var init_state = __esm({
75810
75879
  }
75811
75880
  });
75812
75881
 
75813
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/oauth2/state.mjs
75882
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/oauth2/state.mjs
75814
75883
  function generateIdTokenNonce(provider) {
75815
75884
  return provider.requiresIdTokenNonce ? generateRandomString(32) : void 0;
75816
75885
  }
@@ -75864,7 +75933,7 @@ async function parseState(c3) {
75864
75933
  return parsedData;
75865
75934
  }
75866
75935
  var init_state2 = __esm({
75867
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/oauth2/state.mjs"() {
75936
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/oauth2/state.mjs"() {
75868
75937
  init_random2();
75869
75938
  init_errors4();
75870
75939
  init_oauth();
@@ -79205,7 +79274,7 @@ var init_social_providers = __esm({
79205
79274
  }
79206
79275
  });
79207
79276
 
79208
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/account.mjs
79277
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/account.mjs
79209
79278
  function parseStoredScopes(scope3) {
79210
79279
  if (!scope3) return [];
79211
79280
  return scope3.split(",").map((s2) => s2.trim()).filter(Boolean);
@@ -79301,7 +79370,7 @@ async function getValidAccessToken(ctx, { resolvedUserId, selection, account: re
79301
79370
  }
79302
79371
  var listUserAccounts, linkSocialAccount, unlinkAccount, accountSelectionSchema, getAccessToken, refreshToken, accountInfo;
79303
79372
  var init_account2 = __esm({
79304
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/account.mjs"() {
79373
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/account.mjs"() {
79305
79374
  init_store_capabilities();
79306
79375
  init_schema2();
79307
79376
  init_session_store();
@@ -79794,18 +79863,18 @@ var init_account2 = __esm({
79794
79863
  }
79795
79864
  });
79796
79865
 
79797
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/hide-metadata.mjs
79866
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/hide-metadata.mjs
79798
79867
  var HIDE_METADATA;
79799
79868
  var init_hide_metadata = __esm({
79800
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/hide-metadata.mjs"() {
79869
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/hide-metadata.mjs"() {
79801
79870
  HIDE_METADATA = { scope: "server" };
79802
79871
  }
79803
79872
  });
79804
79873
 
79805
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/callback.mjs
79874
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/callback.mjs
79806
79875
  var schema2, callbackOAuth;
79807
79876
  var init_callback = __esm({
79808
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/callback.mjs"() {
79877
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/callback.mjs"() {
79809
79878
  init_is_api_error2();
79810
79879
  init_cookies2();
79811
79880
  init_helpers();
@@ -80019,13 +80088,13 @@ var init_callback = __esm({
80019
80088
  }
80020
80089
  });
80021
80090
 
80022
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/error.mjs
80091
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/error.mjs
80023
80092
  function sanitize(input4) {
80024
80093
  return input4.replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#39;").replace(/&(?!amp;|lt;|gt;|quot;|#39;|#x[0-9a-fA-F]+;|#[0-9]+;)/g, "&amp;");
80025
80094
  }
80026
80095
  var html, error62;
80027
80096
  var init_error3 = __esm({
80028
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/error.mjs"() {
80097
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/error.mjs"() {
80029
80098
  init_hide_metadata();
80030
80099
  init_env3();
80031
80100
  init_url2();
@@ -80410,10 +80479,10 @@ ${custom2?.disableBackgroundGrid ? "" : `
80410
80479
  }
80411
80480
  });
80412
80481
 
80413
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/ok.mjs
80482
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/ok.mjs
80414
80483
  var ok;
80415
80484
  var init_ok = __esm({
80416
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/ok.mjs"() {
80485
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/ok.mjs"() {
80417
80486
  init_hide_metadata();
80418
80487
  init_api2();
80419
80488
  ok = createAuthEndpoint("/ok", {
@@ -80441,7 +80510,7 @@ var init_ok = __esm({
80441
80510
  }
80442
80511
  });
80443
80512
 
80444
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/password.mjs
80513
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/password.mjs
80445
80514
  function assertPasswordNotTooShort(ctx, password) {
80446
80515
  if (password.length < ctx.context.password.config.minPasswordLength) {
80447
80516
  ctx.context.logger.warn("Password is too short");
@@ -80480,12 +80549,12 @@ async function checkPassword(userId, c3) {
80480
80549
  return true;
80481
80550
  }
80482
80551
  var init_password2 = __esm({
80483
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/password.mjs"() {
80552
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/password.mjs"() {
80484
80553
  init_error2();
80485
80554
  }
80486
80555
  });
80487
80556
 
80488
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/password.mjs
80557
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/password.mjs
80489
80558
  function redirectError(ctx, callbackURL, query) {
80490
80559
  const url2 = callbackURL ? new URL(callbackURL, ctx.baseURL) : new URL(`${ctx.baseURL}/error`);
80491
80560
  if (query) Object.entries(query).forEach(([k2, v2]) => url2.searchParams.set(k2, v2));
@@ -80498,7 +80567,7 @@ function redirectCallback(ctx, callbackURL, query) {
80498
80567
  }
80499
80568
  var requestPasswordReset, requestPasswordResetCallback, resetPassword, verifyPassword2;
80500
80569
  var init_password3 = __esm({
80501
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/password.mjs"() {
80570
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/password.mjs"() {
80502
80571
  init_origin_check();
80503
80572
  init_date();
80504
80573
  init_session2();
@@ -80690,10 +80759,10 @@ var init_password3 = __esm({
80690
80759
  }
80691
80760
  });
80692
80761
 
80693
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/sign-in.mjs
80762
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/sign-in.mjs
80694
80763
  var socialSignInBodySchema, signInSocial, signInEmail;
80695
80764
  var init_sign_in = __esm({
80696
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/sign-in.mjs"() {
80765
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/sign-in.mjs"() {
80697
80766
  init_origin_check();
80698
80767
  init_schema2();
80699
80768
  init_cookies2();
@@ -81064,10 +81133,10 @@ var init_sign_in = __esm({
81064
81133
  }
81065
81134
  });
81066
81135
 
81067
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/sign-out.mjs
81136
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/sign-out.mjs
81068
81137
  var signOutBodySchema, signOutResponse, signOut;
81069
81138
  var init_sign_out = __esm({
81070
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/sign-out.mjs"() {
81139
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/sign-out.mjs"() {
81071
81140
  init_cookies2();
81072
81141
  init_api2();
81073
81142
  init_zod();
@@ -81164,10 +81233,10 @@ var init_sign_out = __esm({
81164
81233
  }
81165
81234
  });
81166
81235
 
81167
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/sign-up.mjs
81236
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/sign-up.mjs
81168
81237
  var signUpEmailBodySchema, signUpEmail;
81169
81238
  var init_sign_up = __esm({
81170
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/sign-up.mjs"() {
81239
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/sign-up.mjs"() {
81171
81240
  init_is_api_error2();
81172
81241
  init_origin_check();
81173
81242
  init_schema2();
@@ -81424,10 +81493,10 @@ var init_sign_up = __esm({
81424
81493
  }
81425
81494
  });
81426
81495
 
81427
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/update-session.mjs
81496
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/update-session.mjs
81428
81497
  var updateSessionBodySchema, updateSession;
81429
81498
  var init_update_session = __esm({
81430
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/update-session.mjs"() {
81499
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/update-session.mjs"() {
81431
81500
  init_schema2();
81432
81501
  init_cookies2();
81433
81502
  init_session2();
@@ -81485,10 +81554,10 @@ var init_update_session = __esm({
81485
81554
  }
81486
81555
  });
81487
81556
 
81488
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/update-user.mjs
81557
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/update-user.mjs
81489
81558
  var updateUserBodySchema, updateUser, changePassword, setPassword, deleteUser, deleteUserCallback, changeEmail;
81490
81559
  var init_update_user = __esm({
81491
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/routes/update-user.mjs"() {
81560
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/routes/update-user.mjs"() {
81492
81561
  init_origin_check();
81493
81562
  init_schema2();
81494
81563
  init_random2();
@@ -81984,7 +82053,7 @@ var init_update_user = __esm({
81984
82053
  }
81985
82054
  });
81986
82055
 
81987
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/dispatch.mjs
82056
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/dispatch.mjs
81988
82057
  function getOperationId(endpoint, fallback) {
81989
82058
  const opts = endpoint.options;
81990
82059
  return opts?.operationId ?? opts?.metadata?.openapi?.operationId ?? fallback ?? endpoint.path ?? "/:virtual";
@@ -82209,7 +82278,7 @@ async function dispatchAuthEndpoint(endpoint, input4) {
82209
82278
  }
82210
82279
  var defuReplaceArrays, hooksSourceWeakMap;
82211
82280
  var init_dispatch = __esm({
82212
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/dispatch.mjs"() {
82281
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/dispatch.mjs"() {
82213
82282
  init_is_api_error2();
82214
82283
  init_url();
82215
82284
  init_context2();
@@ -82228,7 +82297,7 @@ var init_dispatch = __esm({
82228
82297
  }
82229
82298
  });
82230
82299
 
82231
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/to-auth-endpoints.mjs
82300
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/to-auth-endpoints.mjs
82232
82301
  async function resolveDynamicContext(rawCtx, input4) {
82233
82302
  if (rawCtx.baseURL) return rawCtx;
82234
82303
  const source = pickSource(input4);
@@ -82268,7 +82337,7 @@ function toAuthEndpoints(endpoints, ctx) {
82268
82337
  return api;
82269
82338
  }
82270
82339
  var init_to_auth_endpoints = __esm({
82271
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/to-auth-endpoints.mjs"() {
82340
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/to-auth-endpoints.mjs"() {
82272
82341
  init_url();
82273
82342
  init_helpers();
82274
82343
  init_dispatch();
@@ -82277,7 +82346,7 @@ var init_to_auth_endpoints = __esm({
82277
82346
  }
82278
82347
  });
82279
82348
 
82280
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/index.mjs
82349
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/index.mjs
82281
82350
  function checkEndpointConflicts(options, logger3) {
82282
82351
  const endpointRegistry = /* @__PURE__ */ new Map();
82283
82352
  options.plugins?.forEach((plugin) => {
@@ -82402,7 +82471,7 @@ function getEndpoints(ctx, options) {
82402
82471
  }
82403
82472
  var router;
82404
82473
  var init_api4 = __esm({
82405
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/api/index.mjs"() {
82474
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/api/index.mjs"() {
82406
82475
  init_is_api_error2();
82407
82476
  init_origin_check();
82408
82477
  init_rate_limiter();
@@ -83950,7 +84019,7 @@ var init_dist9 = __esm({
83950
84019
  "../../node_modules/.pnpm/@better-auth+memory-adapter@1.7.6_@better-auth+core@1.7.6_@better-auth+utils@0.5.0_@bet_1600a9e00f6d9d30808485fc05650e7d/node_modules/@better-auth/memory-adapter/dist/index.mjs"() {
83951
84020
  init_adapter();
83952
84021
  init_env3();
83953
- memoryAdapter = (db, config3) => {
84022
+ memoryAdapter = (db2, config3) => {
83954
84023
  let lazyOptions = null;
83955
84024
  const buildAdapterFactory = (activeDb2) => createAdapterFactory({
83956
84025
  config: {
@@ -84184,7 +84253,7 @@ var init_dist9 = __esm({
84184
84253
  };
84185
84254
  }
84186
84255
  });
84187
- const adapterCreator = buildAdapterFactory(db);
84256
+ const adapterCreator = buildAdapterFactory(db2);
84188
84257
  return (options) => {
84189
84258
  lazyOptions = options;
84190
84259
  return adapterCreator(options);
@@ -84193,7 +84262,7 @@ var init_dist9 = __esm({
84193
84262
  }
84194
84263
  });
84195
84264
 
84196
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/adapter-base.mjs
84265
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/adapter-base.mjs
84197
84266
  async function getBaseAdapter(options, handleDirectDatabase) {
84198
84267
  let adapter;
84199
84268
  if (!options.database) {
@@ -84215,7 +84284,7 @@ async function getBaseAdapter(options, handleDirectDatabase) {
84215
84284
  return adapter;
84216
84285
  }
84217
84286
  var init_adapter_base = __esm({
84218
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/adapter-base.mjs"() {
84287
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/adapter-base.mjs"() {
84219
84288
  init_db();
84220
84289
  init_env3();
84221
84290
  }
@@ -99240,8 +99309,8 @@ var init_kysely = __esm({
99240
99309
  async execute(callback, options) {
99241
99310
  return this.#props.executor.provideConnection(async (connection) => {
99242
99311
  const executor = this.#props.executor.withConnectionProvider(new SingleConnectionProvider(connection));
99243
- const db = new Kysely({ ...this.#props, executor });
99244
- return await callback(db);
99312
+ const db2 = new Kysely({ ...this.#props, executor });
99313
+ return await callback(db2);
99245
99314
  }, freeze({ signal: options?.signal }));
99246
99315
  }
99247
99316
  };
@@ -101437,8 +101506,8 @@ var init_sqlite_driver = __esm({
101437
101506
  };
101438
101507
  SqliteConnection = class {
101439
101508
  #db;
101440
- constructor(db) {
101441
- this.#db = db;
101509
+ constructor(db2) {
101510
+ this.#db = db2;
101442
101511
  }
101443
101512
  async executeQuery(compiledQuery) {
101444
101513
  const { sql: sql3, parameters } = compiledQuery;
@@ -101534,8 +101603,8 @@ var init_sqlite_introspector = __esm({
101534
101603
  init_sql();
101535
101604
  SqliteIntrospector = class {
101536
101605
  #db;
101537
- constructor(db) {
101538
- this.#db = db;
101606
+ constructor(db2) {
101607
+ this.#db = db2;
101539
101608
  }
101540
101609
  async getSchemas() {
101541
101610
  return [];
@@ -101643,8 +101712,8 @@ var init_sqlite_dialect = __esm({
101643
101712
  createAdapter() {
101644
101713
  return new SqliteAdapter();
101645
101714
  }
101646
- createIntrospector(db) {
101647
- return new SqliteIntrospector(db);
101715
+ createIntrospector(db2) {
101716
+ return new SqliteIntrospector(db2);
101648
101717
  }
101649
101718
  };
101650
101719
  }
@@ -101985,8 +102054,8 @@ var init_mysql_introspector = __esm({
101985
102054
  init_sql();
101986
102055
  MysqlIntrospector = class {
101987
102056
  #db;
101988
- constructor(db) {
101989
- this.#db = db;
102057
+ constructor(db2) {
102058
+ this.#db = db2;
101990
102059
  }
101991
102060
  async getSchemas() {
101992
102061
  let rawSchemas = await this.#db.selectFrom("information_schema.schemata").select("schema_name").$castTo().execute();
@@ -102054,11 +102123,11 @@ var init_mysql_adapter = __esm({
102054
102123
  get supportsReturning() {
102055
102124
  return false;
102056
102125
  }
102057
- async acquireMigrationLock(db, _opt) {
102058
- await sql`select get_lock(${sql.lit(LOCK_ID)}, ${sql.lit(LOCK_TIMEOUT_SECONDS)})`.execute(db);
102126
+ async acquireMigrationLock(db2, _opt) {
102127
+ await sql`select get_lock(${sql.lit(LOCK_ID)}, ${sql.lit(LOCK_TIMEOUT_SECONDS)})`.execute(db2);
102059
102128
  }
102060
- async releaseMigrationLock(db, _opt) {
102061
- await sql`select release_lock(${sql.lit(LOCK_ID)})`.execute(db);
102129
+ async releaseMigrationLock(db2, _opt) {
102130
+ await sql`select release_lock(${sql.lit(LOCK_ID)})`.execute(db2);
102062
102131
  }
102063
102132
  };
102064
102133
  }
@@ -102086,8 +102155,8 @@ var init_mysql_dialect = __esm({
102086
102155
  createAdapter() {
102087
102156
  return new MysqlAdapter();
102088
102157
  }
102089
- createIntrospector(db) {
102090
- return new MysqlIntrospector(db);
102158
+ createIntrospector(db2) {
102159
+ return new MysqlIntrospector(db2);
102091
102160
  }
102092
102161
  };
102093
102162
  }
@@ -102274,8 +102343,8 @@ var init_postgres_introspector = __esm({
102274
102343
  init_sql();
102275
102344
  PostgresIntrospector = class {
102276
102345
  #db;
102277
- constructor(db) {
102278
- this.#db = db;
102346
+ constructor(db2) {
102347
+ this.#db = db2;
102279
102348
  }
102280
102349
  async getSchemas() {
102281
102350
  let rawSchemas = await this.#db.selectFrom("pg_catalog.pg_namespace").select("nspname").$castTo().execute();
@@ -102370,8 +102439,8 @@ var init_postgres_adapter = __esm({
102370
102439
  get supportsReturning() {
102371
102440
  return true;
102372
102441
  }
102373
- async acquireMigrationLock(db, _opt) {
102374
- await sql`select pg_advisory_xact_lock(${sql.lit(LOCK_ID2)})`.execute(db);
102442
+ async acquireMigrationLock(db2, _opt) {
102443
+ await sql`select pg_advisory_xact_lock(${sql.lit(LOCK_ID2)})`.execute(db2);
102375
102444
  }
102376
102445
  async releaseMigrationLock(_db, _opt) {
102377
102446
  }
@@ -102401,8 +102470,8 @@ var init_postgres_dialect = __esm({
102401
102470
  createAdapter() {
102402
102471
  return new PostgresAdapter();
102403
102472
  }
102404
- createIntrospector(db) {
102405
- return new PostgresIntrospector(db);
102473
+ createIntrospector(db2) {
102474
+ return new PostgresIntrospector(db2);
102406
102475
  }
102407
102476
  };
102408
102477
  }
@@ -102425,8 +102494,8 @@ var init_mssql_adapter = __esm({
102425
102494
  get supportsOutput() {
102426
102495
  return true;
102427
102496
  }
102428
- async acquireMigrationLock(db) {
102429
- await sql`exec sp_getapplock @DbPrincipal = ${sql.lit("dbo")}, @Resource = ${sql.lit(DEFAULT_MIGRATION_TABLE)}, @LockMode = ${sql.lit("Exclusive")}`.execute(db);
102497
+ async acquireMigrationLock(db2) {
102498
+ await sql`exec sp_getapplock @DbPrincipal = ${sql.lit("dbo")}, @Resource = ${sql.lit(DEFAULT_MIGRATION_TABLE)}, @LockMode = ${sql.lit("Exclusive")}`.execute(db2);
102430
102499
  }
102431
102500
  async releaseMigrationLock() {
102432
102501
  }
@@ -102793,8 +102862,8 @@ var init_mssql_introspector = __esm({
102793
102862
  init_object_utils();
102794
102863
  MssqlIntrospector = class {
102795
102864
  #db;
102796
- constructor(db) {
102797
- this.#db = db;
102865
+ constructor(db2) {
102866
+ this.#db = db2;
102798
102867
  }
102799
102868
  async getSchemas() {
102800
102869
  return await this.#db.selectFrom("sys.schemas").select("name").execute();
@@ -102970,8 +103039,8 @@ var init_mssql_dialect = __esm({
102970
103039
  createAdapter() {
102971
103040
  return new MssqlAdapter();
102972
103041
  }
102973
- createIntrospector(db) {
102974
- return new MssqlIntrospector(db);
103042
+ createIntrospector(db2) {
103043
+ return new MssqlIntrospector(db2);
102975
103044
  }
102976
103045
  };
102977
103046
  }
@@ -103308,12 +103377,12 @@ function sqliteIntegerPrimaryKeyColumn(columns) {
103308
103377
  const primaryKey2 = primaryKeys.length === 1 ? primaryKeys[0] : void 0;
103309
103378
  return primaryKey2?.type.toLowerCase() === "integer" ? primaryKey2.name : void 0;
103310
103379
  }
103311
- async function sqliteGeneratedPrimaryKeyColumn(db, name2, columns) {
103380
+ async function sqliteGeneratedPrimaryKeyColumn(db2, name2, columns) {
103312
103381
  const column = sqliteIntegerPrimaryKeyColumn(columns);
103313
103382
  if (!column) return;
103314
103383
  const { rows } = await sql`
103315
103384
  PRAGMA index_list(${sql.id(name2)})
103316
- `.execute(db.withoutPlugins());
103385
+ `.execute(db2.withoutPlugins());
103317
103386
  return rows.some((index2) => index2.origin === "pk") ? void 0 : column;
103318
103387
  }
103319
103388
  function toSqliteTableMetadata(table2, columns, autoIncrementColumn) {
@@ -103329,24 +103398,24 @@ function toSqliteTableMetadata(table2, columns, autoIncrementColumn) {
103329
103398
  }))
103330
103399
  };
103331
103400
  }
103332
- async function readTableMetadata(db, name2) {
103401
+ async function readTableMetadata(db2, name2) {
103333
103402
  const { rows: columns } = await sql`
103334
103403
  PRAGMA table_info(${sql.id(name2)})
103335
- `.execute(db.withoutPlugins());
103404
+ `.execute(db2.withoutPlugins());
103336
103405
  if (columns.length === 0) return;
103337
- const generatedColumn = await sqliteGeneratedPrimaryKeyColumn(db, name2, columns);
103406
+ const generatedColumn = await sqliteGeneratedPrimaryKeyColumn(db2, name2, columns);
103338
103407
  return toSqliteTableMetadata({ name: name2 }, columns, generatedColumn);
103339
103408
  }
103340
- async function introspectSqliteTables(db, tableNames) {
103409
+ async function introspectSqliteTables(db2, tableNames) {
103341
103410
  if (tableNames.length === 0) return [];
103342
103411
  try {
103343
- return await db.introspection.getTables();
103412
+ return await db2.introspection.getTables();
103344
103413
  } catch {
103345
- return (await Promise.all(tableNames.map((name2) => readTableMetadata(db, name2)))).filter((table2) => table2 !== void 0);
103414
+ return (await Promise.all(tableNames.map((name2) => readTableMetadata(db2, name2)))).filter((table2) => table2 !== void 0);
103346
103415
  }
103347
103416
  }
103348
- function createSqliteIntrospector(db) {
103349
- const systemDb = db;
103417
+ function createSqliteIntrospector(db2) {
103418
+ const systemDb = db2;
103350
103419
  async function getSchemas() {
103351
103420
  return [];
103352
103421
  }
@@ -103355,7 +103424,7 @@ function createSqliteIntrospector(db) {
103355
103424
  if (!options.withInternalKyselyTables) query = query.where("name", "!=", DEFAULT_MIGRATION_TABLE2).where("name", "!=", DEFAULT_MIGRATION_LOCK_TABLE2);
103356
103425
  const tables = await query.execute();
103357
103426
  return Promise.all(tables.map(async ({ name: name2 }) => {
103358
- const columns = await db.selectFrom(sql`pragma_table_info(${name2})`.as("table_info")).select([
103427
+ const columns = await db2.selectFrom(sql`pragma_table_info(${name2})`.as("table_info")).select([
103359
103428
  "cid",
103360
103429
  "name",
103361
103430
  "type",
@@ -103363,7 +103432,7 @@ function createSqliteIntrospector(db) {
103363
103432
  "dflt_value",
103364
103433
  "pk"
103365
103434
  ]).execute();
103366
- const generatedColumn = await sqliteGeneratedPrimaryKeyColumn(db, name2, columns);
103435
+ const generatedColumn = await sqliteGeneratedPrimaryKeyColumn(db2, name2, columns);
103367
103436
  return toSqliteTableMetadata({ name: name2 }, columns, generatedColumn);
103368
103437
  }));
103369
103438
  }
@@ -103466,8 +103535,8 @@ var init_bun_sqlite_dialect_DoOVo4ja = __esm({
103466
103535
  };
103467
103536
  BunSqliteConnection = class {
103468
103537
  #db;
103469
- constructor(db) {
103470
- this.#db = db;
103538
+ constructor(db2) {
103539
+ this.#db = db2;
103471
103540
  }
103472
103541
  executeQuery(compiledQuery) {
103473
103542
  const { sql: sql3, parameters } = compiledQuery;
@@ -103529,8 +103598,8 @@ var init_bun_sqlite_dialect_DoOVo4ja = __esm({
103529
103598
  createAdapter() {
103530
103599
  return new BunSqliteAdapter();
103531
103600
  }
103532
- createIntrospector(db) {
103533
- return createSqliteIntrospector(db);
103601
+ createIntrospector(db2) {
103602
+ return createSqliteIntrospector(db2);
103534
103603
  }
103535
103604
  };
103536
103605
  }
@@ -103599,8 +103668,8 @@ var init_node_sqlite_dialect = __esm({
103599
103668
  };
103600
103669
  NodeSqliteConnection = class {
103601
103670
  #db;
103602
- constructor(db) {
103603
- this.#db = db;
103671
+ constructor(db2) {
103672
+ this.#db = db2;
103604
103673
  }
103605
103674
  executeQuery(compiledQuery) {
103606
103675
  const { sql: sql3, parameters } = compiledQuery;
@@ -103662,8 +103731,8 @@ var init_node_sqlite_dialect = __esm({
103662
103731
  createAdapter() {
103663
103732
  return new NodeSqliteAdapter();
103664
103733
  }
103665
- createIntrospector(db) {
103666
- return createSqliteIntrospector(db);
103734
+ createIntrospector(db2) {
103735
+ return createSqliteIntrospector(db2);
103667
103736
  }
103668
103737
  };
103669
103738
  }
@@ -103741,8 +103810,8 @@ var init_d1_sqlite_dialect_Cru74LbR = __esm({
103741
103810
  };
103742
103811
  D1SqliteConnection = class {
103743
103812
  #db;
103744
- constructor(db) {
103745
- this.#db = db;
103813
+ constructor(db2) {
103814
+ this.#db = db2;
103746
103815
  }
103747
103816
  async executeQuery(compiledQuery) {
103748
103817
  const results = await this.#db.prepare(compiledQuery.sql).bind(...compiledQuery.parameters).all();
@@ -103760,8 +103829,8 @@ var init_d1_sqlite_dialect_Cru74LbR = __esm({
103760
103829
  D1SqliteIntrospector = class {
103761
103830
  #db;
103762
103831
  #d1;
103763
- constructor(db, d1) {
103764
- this.#db = db;
103832
+ constructor(db2, d1) {
103833
+ this.#db = db2;
103765
103834
  this.#d1 = d1;
103766
103835
  }
103767
103836
  async getSchemas() {
@@ -103808,29 +103877,29 @@ var init_d1_sqlite_dialect_Cru74LbR = __esm({
103808
103877
  createAdapter() {
103809
103878
  return new D1SqliteAdapter();
103810
103879
  }
103811
- createIntrospector(db) {
103812
- return new D1SqliteIntrospector(db, this.#config.database);
103880
+ createIntrospector(db2) {
103881
+ return new D1SqliteIntrospector(db2, this.#config.database);
103813
103882
  }
103814
103883
  };
103815
103884
  }
103816
103885
  });
103817
103886
 
103818
103887
  // ../../node_modules/.pnpm/@better-auth+kysely-adapter@1.7.6_@better-auth+core@1.7.6_@better-auth+utils@0.5.0_@bet_1bca8a93d6e8826074e1b2b5eef24c2d/node_modules/@better-auth/kysely-adapter/dist/index.mjs
103819
- function getKyselyDatabaseType(db) {
103820
- if (!db) return null;
103821
- if ("dialect" in db) return getKyselyDatabaseType(db.dialect);
103822
- if ("createDriver" in db) {
103823
- if (db instanceof SqliteDialect) return "sqlite";
103824
- if (db instanceof MysqlDialect) return "mysql";
103825
- if (db instanceof PostgresDialect) return "postgres";
103826
- if (db instanceof MssqlDialect) return "mssql";
103827
- }
103828
- if ("aggregate" in db) return "sqlite";
103829
- if ("getConnection" in db) return "mysql";
103830
- if ("connect" in db) return "postgres";
103831
- if ("fileControl" in db) return "sqlite";
103832
- if ("open" in db && "close" in db && "prepare" in db) return "sqlite";
103833
- if ("batch" in db && "exec" in db && "prepare" in db) return "sqlite";
103888
+ function getKyselyDatabaseType(db2) {
103889
+ if (!db2) return null;
103890
+ if ("dialect" in db2) return getKyselyDatabaseType(db2.dialect);
103891
+ if ("createDriver" in db2) {
103892
+ if (db2 instanceof SqliteDialect) return "sqlite";
103893
+ if (db2 instanceof MysqlDialect) return "mysql";
103894
+ if (db2 instanceof PostgresDialect) return "postgres";
103895
+ if (db2 instanceof MssqlDialect) return "mssql";
103896
+ }
103897
+ if ("aggregate" in db2) return "sqlite";
103898
+ if ("getConnection" in db2) return "mysql";
103899
+ if ("connect" in db2) return "postgres";
103900
+ if ("fileControl" in db2) return "sqlite";
103901
+ if ("open" in db2 && "close" in db2 && "prepare" in db2) return "sqlite";
103902
+ if ("batch" in db2 && "exec" in db2 && "prepare" in db2) return "sqlite";
103834
103903
  return null;
103835
103904
  }
103836
103905
  function checkSchemaName(schemaName, databaseType) {
@@ -103876,11 +103945,11 @@ function toIntrospectedTables(tables) {
103876
103945
  }))
103877
103946
  }));
103878
103947
  }
103879
- function toPhysicalSchema(db, expected) {
103948
+ function toPhysicalSchema(db2, expected) {
103880
103949
  const physical = {};
103881
103950
  for (const [table2, definition] of Object.entries(expected)) {
103882
103951
  const entries = Object.entries(definition.fields);
103883
- const sent = sentIdentifiers(db, table2, [definition.idColumn ?? "id", ...entries.map(([column]) => column)]);
103952
+ const sent = sentIdentifiers(db2, table2, [definition.idColumn ?? "id", ...entries.map(([column]) => column)]);
103884
103953
  const fields = {};
103885
103954
  entries.forEach(([column, attribute], index2) => {
103886
103955
  fields[sent.columns[index2 + 1] ?? column] = attribute;
@@ -103894,8 +103963,8 @@ function toPhysicalSchema(db, expected) {
103894
103963
  }
103895
103964
  return physical;
103896
103965
  }
103897
- function sentIdentifiers(db, table2, columns) {
103898
- const { query } = db.selectFrom(table2).select(columns).compile();
103966
+ function sentIdentifiers(db2, table2, columns) {
103967
+ const { query } = db2.selectFrom(table2).select(columns).compile();
103899
103968
  if (!SelectQueryNode.is(query)) return {
103900
103969
  table: table2,
103901
103970
  columns: []
@@ -103908,26 +103977,26 @@ function sentIdentifiers(db, table2, columns) {
103908
103977
  columns: (query.selections ?? []).map(({ selection }) => ReferenceNode.is(selection) && ColumnNode.is(selection.column) ? selection.column.column.name : void 0)
103909
103978
  };
103910
103979
  }
103911
- async function getPostgresSchema(db) {
103980
+ async function getPostgresSchema(db2) {
103912
103981
  return (await sql`
103913
103982
  SELECT pg_catalog.current_schema() AS schema
103914
- `.execute(db.withoutPlugins())).rows[0]?.schema ?? "public";
103983
+ `.execute(db2.withoutPlugins())).rows[0]?.schema ?? "public";
103915
103984
  }
103916
- async function getMssqlSchema(db) {
103985
+ async function getMssqlSchema(db2) {
103917
103986
  return (await sql`
103918
103987
  SELECT SCHEMA_NAME() AS "schemaName"
103919
- `.execute(db.withoutPlugins())).rows[0]?.schemaName || "dbo";
103988
+ `.execute(db2.withoutPlugins())).rows[0]?.schemaName || "dbo";
103920
103989
  }
103921
- async function schemaSearchPath(db, dbType) {
103990
+ async function schemaSearchPath(db2, dbType) {
103922
103991
  if (dbType === "postgres") return (await sql`
103923
103992
  SELECT pg_catalog.current_schemas(true)::text[] AS schemas
103924
- `.execute(db.withoutPlugins())).rows[0]?.schemas ?? [];
103925
- if (dbType === "mssql") return [await getMssqlSchema(db), "dbo"];
103993
+ `.execute(db2.withoutPlugins())).rows[0]?.schemas ?? [];
103994
+ if (dbType === "mssql") return [await getMssqlSchema(db2), "dbo"];
103926
103995
  }
103927
- async function findSchemaProblems(db, dbType, expected) {
103928
- const physical = toPhysicalSchema(db, expected);
103929
- if (dbType === "sqlite") return diffSchema(physical, toIntrospectedTables(await introspectSqliteTables(db, Object.entries(physical).flatMap(([name2, table2]) => table2.disableMigrations ? [] : [name2]))));
103930
- return db.connection().execute(async (connection) => {
103996
+ async function findSchemaProblems(db2, dbType, expected) {
103997
+ const physical = toPhysicalSchema(db2, expected);
103998
+ if (dbType === "sqlite") return diffSchema(physical, toIntrospectedTables(await introspectSqliteTables(db2, Object.entries(physical).flatMap(([name2, table2]) => table2.disableMigrations ? [] : [name2]))));
103999
+ return db2.connection().execute(async (connection) => {
103931
104000
  const searchPath = await schemaSearchPath(connection, dbType);
103932
104001
  const tables = toIntrospectedTables(await connection.introspection.getTables());
103933
104002
  for (const [name2, table2] of Object.entries(physical)) {
@@ -103948,60 +104017,60 @@ var init_dist11 = __esm({
103948
104017
  init_env3();
103949
104018
  init_string();
103950
104019
  createKyselyAdapter = async (config3) => {
103951
- const db = config3.database;
103952
- if (!db) return {
104020
+ const db2 = config3.database;
104021
+ if (!db2) return {
103953
104022
  kysely: null,
103954
104023
  databaseType: null,
103955
104024
  introspectIndexes: void 0,
103956
104025
  schemaName: void 0,
103957
104026
  transaction: void 0
103958
104027
  };
103959
- if ("db" in db) {
103960
- const schemaName = db.schemaName;
103961
- checkSchemaName(schemaName, db.type);
104028
+ if ("db" in db2) {
104029
+ const schemaName = db2.schemaName;
104030
+ checkSchemaName(schemaName, db2.type);
103962
104031
  return {
103963
- kysely: schemaName ? db.db.withSchema(schemaName) : db.db,
103964
- databaseType: db.type,
104032
+ kysely: schemaName ? db2.db.withSchema(schemaName) : db2.db,
104033
+ databaseType: db2.type,
103965
104034
  introspectIndexes: void 0,
103966
104035
  schemaName,
103967
- transaction: db.transaction
104036
+ transaction: db2.transaction
103968
104037
  };
103969
104038
  }
103970
- if ("dialect" in db) {
103971
- const schemaName = db.schemaName;
103972
- checkSchemaName(schemaName, db.type);
103973
- const kysely = new Kysely({ dialect: db.dialect });
104039
+ if ("dialect" in db2) {
104040
+ const schemaName = db2.schemaName;
104041
+ checkSchemaName(schemaName, db2.type);
104042
+ const kysely = new Kysely({ dialect: db2.dialect });
103974
104043
  return {
103975
104044
  kysely: schemaName ? kysely.withSchema(schemaName) : kysely,
103976
- databaseType: db.type,
104045
+ databaseType: db2.type,
103977
104046
  introspectIndexes: void 0,
103978
104047
  schemaName,
103979
- transaction: db.transaction
104048
+ transaction: db2.transaction
103980
104049
  };
103981
104050
  }
103982
104051
  let dialect = void 0;
103983
104052
  let introspectIndexes = void 0;
103984
104053
  let transaction = void 0;
103985
- const databaseType = getKyselyDatabaseType(db);
103986
- if ("createDriver" in db) dialect = db;
103987
- if ("aggregate" in db && !("createSession" in db)) {
103988
- dialect = new SqliteDialect({ database: db });
104054
+ const databaseType = getKyselyDatabaseType(db2);
104055
+ if ("createDriver" in db2) dialect = db2;
104056
+ if ("aggregate" in db2 && !("createSession" in db2)) {
104057
+ dialect = new SqliteDialect({ database: db2 });
103989
104058
  transaction = true;
103990
104059
  }
103991
- if ("getConnection" in db) {
103992
- dialect = new MysqlDialect(db);
104060
+ if ("getConnection" in db2) {
104061
+ dialect = new MysqlDialect(db2);
103993
104062
  transaction = true;
103994
104063
  }
103995
- if ("connect" in db) {
103996
- dialect = new PostgresDialect({ pool: db });
104064
+ if ("connect" in db2) {
104065
+ dialect = new PostgresDialect({ pool: db2 });
103997
104066
  transaction = true;
103998
104067
  }
103999
- if ("fileControl" in db) {
104068
+ if ("fileControl" in db2) {
104000
104069
  const { BunSqliteDialect: BunSqliteDialect2 } = await Promise.resolve().then(() => (init_bun_sqlite_dialect_DoOVo4ja(), bun_sqlite_dialect_DoOVo4ja_exports));
104001
- dialect = new BunSqliteDialect2({ database: db });
104070
+ dialect = new BunSqliteDialect2({ database: db2 });
104002
104071
  transaction = true;
104003
104072
  }
104004
- if ("createSession" in db) {
104073
+ if ("createSession" in db2) {
104005
104074
  let DatabaseSync = void 0;
104006
104075
  try {
104007
104076
  const nodeSqlite = "node:sqlite";
@@ -104013,16 +104082,16 @@ var init_dist11 = __esm({
104013
104082
  } catch (error63) {
104014
104083
  if (error63 !== null && typeof error63 === "object" && "code" in error63 && error63.code !== "ERR_UNKNOWN_BUILTIN_MODULE") throw error63;
104015
104084
  }
104016
- if (DatabaseSync && db instanceof DatabaseSync) {
104085
+ if (DatabaseSync && db2 instanceof DatabaseSync) {
104017
104086
  const { NodeSqliteDialect: NodeSqliteDialect2 } = await Promise.resolve().then(() => (init_node_sqlite_dialect(), node_sqlite_dialect_exports));
104018
- dialect = new NodeSqliteDialect2({ database: db });
104087
+ dialect = new NodeSqliteDialect2({ database: db2 });
104019
104088
  transaction = true;
104020
104089
  }
104021
104090
  }
104022
- if ("batch" in db && "exec" in db && "prepare" in db) {
104091
+ if ("batch" in db2 && "exec" in db2 && "prepare" in db2) {
104023
104092
  const { createD1IndexIntrospector: createD1IndexIntrospector2, D1SqliteDialect: D1SqliteDialect2 } = await Promise.resolve().then(() => (init_d1_sqlite_dialect_Cru74LbR(), d1_sqlite_dialect_Cru74LbR_exports));
104024
- dialect = new D1SqliteDialect2({ database: db });
104025
- introspectIndexes = createD1IndexIntrospector2(db);
104093
+ dialect = new D1SqliteDialect2({ database: db2 });
104094
+ introspectIndexes = createD1IndexIntrospector2(db2);
104026
104095
  transaction = false;
104027
104096
  }
104028
104097
  return {
@@ -104033,10 +104102,10 @@ var init_dist11 = __esm({
104033
104102
  transaction
104034
104103
  };
104035
104104
  };
104036
- kyselyAdapter = (db, config3) => {
104105
+ kyselyAdapter = (db2, config3) => {
104037
104106
  let lazyOptions = null;
104038
104107
  let mysqlNoIdWarned = false;
104039
- const createCustomAdapter = (db2, inTransaction = false) => {
104108
+ const createCustomAdapter = (db3, inTransaction = false) => {
104040
104109
  return ({ getFieldName, schema: schema3, getDefaultFieldName, getDefaultModelName, getFieldAttributes, getModelName, options }) => {
104041
104110
  if (config3?.type === "mysql" && options.advanced?.database?.generateId === false && !mysqlNoIdWarned) {
104042
104111
  mysqlNoIdWarned = true;
@@ -104082,7 +104151,7 @@ var init_dist11 = __esm({
104082
104151
  reselectField = where[0].field;
104083
104152
  reselectValue = values2[reselectField] !== void 0 ? values2[reselectField] : where[0].value;
104084
104153
  } else return null;
104085
- return await db2.selectFrom(model).selectAll().where(getFieldName({
104154
+ return await db3.selectFrom(model).selectAll().where(getFieldName({
104086
104155
  model: modelKey,
104087
104156
  field: reselectField
104088
104157
  }), reselectValue === null ? "is" : "=", reselectValue).limit(1).executeTakeFirst();
@@ -104126,7 +104195,7 @@ var init_dist11 = __esm({
104126
104195
  logger2.warn(`[Kysely Adapter] Unable to safely identify the inserted "${model}" row on MySQL. Enable Better Auth ID generation or use generateId: "serial" for reliable behavior.`);
104127
104196
  return null;
104128
104197
  };
104129
- return inTransaction ? fetchInserted(db2) : db2.transaction().execute(fetchInserted);
104198
+ return inTransaction ? fetchInserted(db3) : db3.transaction().execute(fetchInserted);
104130
104199
  }
104131
104200
  if (config3?.type === "mssql") return await builder.outputAll("inserted").executeTakeFirst();
104132
104201
  return await builder.returningAll().executeTakeFirst();
@@ -104268,11 +104337,11 @@ var init_dist11 = __esm({
104268
104337
  }
104269
104338
  return {
104270
104339
  async create({ data, model, modelKey = model }) {
104271
- return await withReturning(data, db2.insertInto(model).values(data), model, modelKey, []);
104340
+ return await withReturning(data, db3.insertInto(model).values(data), model, modelKey, []);
104272
104341
  },
104273
104342
  async findOne({ model, modelKey = model, where, select: select2, join: join62 }) {
104274
104343
  const { and: and2, or: or2 } = convertWhereClause(model, modelKey, where);
104275
- let query = db2.selectFrom((eb) => {
104344
+ let query = db3.selectFrom((eb) => {
104276
104345
  let b2 = eb.selectFrom(model);
104277
104346
  if (and2) b2 = b2.where((eb2) => eb2.and(and2.map((expr) => expr(eb2))));
104278
104347
  if (or2) b2 = b2.where((eb2) => eb2.or(or2.map((expr) => expr(eb2))));
@@ -104297,7 +104366,7 @@ var init_dist11 = __esm({
104297
104366
  },
104298
104367
  async findMany({ model, modelKey = model, where, limit, select: select2, offset, sortBy, join: join62 }) {
104299
104368
  const { and: and2, or: or2 } = convertWhereClause(model, modelKey, where);
104300
- let query = db2.selectFrom((eb) => {
104369
+ let query = db3.selectFrom((eb) => {
104301
104370
  let b2 = eb.selectFrom(model);
104302
104371
  if (config3?.type === "mssql") {
104303
104372
  if (offset !== void 0) {
@@ -104342,14 +104411,14 @@ var init_dist11 = __esm({
104342
104411
  async update({ model, modelKey = model, where, update: values2 }) {
104343
104412
  if (where.length === 0) return null;
104344
104413
  const { and: and2, or: or2 } = convertWhereClause(model, modelKey, where);
104345
- let query = db2.updateTable(model).set(values2);
104414
+ let query = db3.updateTable(model).set(values2);
104346
104415
  if (and2) query = query.where((eb) => eb.and(and2.map((expr) => expr(eb))));
104347
104416
  if (or2) query = query.where((eb) => eb.or(or2.map((expr) => expr(eb))));
104348
104417
  return await withReturning(values2, query, model, modelKey, where);
104349
104418
  },
104350
104419
  async updateMany({ model, modelKey = model, where, update: values2 }) {
104351
104420
  const { and: and2, or: or2 } = convertWhereClause(model, modelKey, where);
104352
- let query = db2.updateTable(model).set(values2);
104421
+ let query = db3.updateTable(model).set(values2);
104353
104422
  if (and2) query = query.where((eb) => eb.and(and2.map((expr) => expr(eb))));
104354
104423
  if (or2) query = query.where((eb) => eb.or(or2.map((expr) => expr(eb))));
104355
104424
  const res = (await query.executeTakeFirst()).numUpdatedRows;
@@ -104357,7 +104426,7 @@ var init_dist11 = __esm({
104357
104426
  },
104358
104427
  async count({ model, modelKey = model, where }) {
104359
104428
  const { and: and2, or: or2 } = convertWhereClause(model, modelKey, where);
104360
- let query = db2.selectFrom(model).select(db2.fn.count("id").as("count"));
104429
+ let query = db3.selectFrom(model).select(db3.fn.count("id").as("count"));
104361
104430
  if (and2) query = query.where((eb) => eb.and(and2.map((expr) => expr(eb))));
104362
104431
  if (or2) query = query.where((eb) => eb.or(or2.map((expr) => expr(eb))));
104363
104432
  const res = await query.execute();
@@ -104367,14 +104436,14 @@ var init_dist11 = __esm({
104367
104436
  },
104368
104437
  async delete({ model, modelKey = model, where }) {
104369
104438
  const { and: and2, or: or2 } = convertWhereClause(model, modelKey, where);
104370
- let query = db2.deleteFrom(model);
104439
+ let query = db3.deleteFrom(model);
104371
104440
  if (and2) query = query.where((eb) => eb.and(and2.map((expr) => expr(eb))));
104372
104441
  if (or2) query = query.where((eb) => eb.or(or2.map((expr) => expr(eb))));
104373
104442
  await query.execute();
104374
104443
  },
104375
104444
  async deleteMany({ model, modelKey = model, where }) {
104376
104445
  const { and: and2, or: or2 } = convertWhereClause(model, modelKey, where);
104377
- let query = db2.deleteFrom(model);
104446
+ let query = db3.deleteFrom(model);
104378
104447
  if (and2) query = query.where((eb) => eb.and(and2.map((expr) => expr(eb))));
104379
104448
  if (or2) query = query.where((eb) => eb.or(or2.map((expr) => expr(eb))));
104380
104449
  const res = (await query.executeTakeFirst()).numDeletedRows;
@@ -104391,10 +104460,10 @@ var init_dist11 = __esm({
104391
104460
  model: modelKey,
104392
104461
  field: "id"
104393
104462
  });
104394
- const deleteSelectedRow = async (db3, row2) => {
104463
+ const deleteSelectedRow = async (db4, row2) => {
104395
104464
  const targetId = row2[idField] ?? row2.id;
104396
104465
  if (targetId === void 0 || targetId === null) return null;
104397
- const query = db3.deleteFrom(model).where(`${model}.${idField}`, "=", targetId);
104466
+ const query = db4.deleteFrom(model).where(`${model}.${idField}`, "=", targetId);
104398
104467
  if (config3?.type === "mysql") {
104399
104468
  const result2 = await query.executeTakeFirst();
104400
104469
  return Number(result2.numDeletedRows) > 0 ? row2 : null;
@@ -104412,11 +104481,11 @@ var init_dist11 = __esm({
104412
104481
  if (!row2) return null;
104413
104482
  return deleteSelectedRow(trx, row2);
104414
104483
  };
104415
- return inTransaction ? claimFromTransaction(db2) : db2.transaction().execute(claimFromTransaction);
104484
+ return inTransaction ? claimFromTransaction(db3) : db3.transaction().execute(claimFromTransaction);
104416
104485
  }
104417
- const selectIds = applyWhere(db2.selectFrom(model).select(`${model}.${idField}`));
104486
+ const selectIds = applyWhere(db3.selectFrom(model).select(`${model}.${idField}`));
104418
104487
  const targetIds = config3?.type === "mssql" ? selectIds.top(1) : selectIds.limit(1);
104419
- return deleteWithReturning(db2.deleteFrom(model).where(`${model}.${idField}`, "in", targetIds));
104488
+ return deleteWithReturning(db3.deleteFrom(model).where(`${model}.${idField}`, "in", targetIds));
104420
104489
  },
104421
104490
  async incrementOne({ model, modelKey = model, where, increment, set: set3 }) {
104422
104491
  const { and: and2, or: or2 } = convertWhereClause(model, modelKey, where);
@@ -104441,11 +104510,11 @@ var init_dist11 = __esm({
104441
104510
  if (Number(updated.numUpdatedRows) === 0) return null;
104442
104511
  return await trx.selectFrom(model).selectAll().where(`${model}.${idField}`, "=", targetId).limit(1).executeTakeFirst() ?? null;
104443
104512
  };
104444
- return inTransaction ? incrementInTransaction(db2) : db2.transaction().execute(incrementInTransaction);
104513
+ return inTransaction ? incrementInTransaction(db3) : db3.transaction().execute(incrementInTransaction);
104445
104514
  }
104446
- const selectIds = applyWhere(db2.selectFrom(model).select(`${model}.${idField}`));
104515
+ const selectIds = applyWhere(db3.selectFrom(model).select(`${model}.${idField}`));
104447
104516
  const targetIds = config3?.type === "mssql" ? selectIds.top(1) : selectIds.limit(1);
104448
- const updateQuery = applyWhere(db2.updateTable(model).set(assignments)).where(`${model}.${idField}`, "in", targetIds);
104517
+ const updateQuery = applyWhere(db3.updateTable(model).set(assignments)).where(`${model}.${idField}`, "in", targetIds);
104449
104518
  if (config3?.type === "mssql") return await updateQuery.outputAll("inserted").executeTakeFirst() ?? null;
104450
104519
  return await updateQuery.returningAll().executeTakeFirst() ?? null;
104451
104520
  },
@@ -104465,7 +104534,7 @@ var init_dist11 = __esm({
104465
104534
  supportsJSON: config3?.type === "postgres" ? true : false,
104466
104535
  supportsArrays: false,
104467
104536
  supportsUUIDs: config3?.type === "postgres" ? true : false,
104468
- transaction: config3?.transaction ? (cb) => db.transaction().execute((trx) => {
104537
+ transaction: config3?.transaction ? (cb) => db2.transaction().execute((trx) => {
104469
104538
  return cb(createAdapterFactory({
104470
104539
  config: {
104471
104540
  ...adapterOptions.config,
@@ -104475,20 +104544,20 @@ var init_dist11 = __esm({
104475
104544
  })(lazyOptions));
104476
104545
  }) : false
104477
104546
  },
104478
- adapter: createCustomAdapter(db)
104547
+ adapter: createCustomAdapter(db2)
104479
104548
  };
104480
104549
  const adapter = createAdapterFactory(adapterOptions);
104481
104550
  return (options) => {
104482
104551
  lazyOptions = options;
104483
104552
  const instance = adapter(options);
104484
- registerSchemaCheck(instance, createSchemaCheck(() => findSchemaProblems(db, config3?.type, getExpectedSchema(options, { usePlural: config3?.usePlural })), "database", options.database), { runtimeEnabled: checksSchema(options) });
104553
+ registerSchemaCheck(instance, createSchemaCheck(() => findSchemaProblems(db2, config3?.type, getExpectedSchema(options, { usePlural: config3?.usePlural })), "database", options.database), { runtimeEnabled: checksSchema(options) });
104485
104554
  return instance;
104486
104555
  };
104487
104556
  };
104488
104557
  }
104489
104558
  });
104490
104559
 
104491
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/adapters/kysely-adapter/index.mjs
104560
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/adapters/kysely-adapter/index.mjs
104492
104561
  var kysely_adapter_exports = {};
104493
104562
  __export(kysely_adapter_exports, {
104494
104563
  createKyselyAdapter: () => createKyselyAdapter,
@@ -104500,12 +104569,12 @@ __export(kysely_adapter_exports, {
104500
104569
  toPhysicalSchema: () => toPhysicalSchema
104501
104570
  });
104502
104571
  var init_kysely_adapter = __esm({
104503
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/adapters/kysely-adapter/index.mjs"() {
104572
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/adapters/kysely-adapter/index.mjs"() {
104504
104573
  init_dist11();
104505
104574
  }
104506
104575
  });
104507
104576
 
104508
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/adapter-kysely.mjs
104577
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/adapter-kysely.mjs
104509
104578
  async function getAdapter(options) {
104510
104579
  return getBaseAdapter(options, async (opts) => {
104511
104580
  const { createKyselyAdapter: createKyselyAdapter2, kyselyAdapter: kyselyAdapter2 } = await Promise.resolve().then(() => (init_kysely_adapter(), kysely_adapter_exports));
@@ -104519,13 +104588,13 @@ async function getAdapter(options) {
104519
104588
  });
104520
104589
  }
104521
104590
  var init_adapter_kysely = __esm({
104522
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/adapter-kysely.mjs"() {
104591
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/adapter-kysely.mjs"() {
104523
104592
  init_adapter_base();
104524
104593
  init_error2();
104525
104594
  }
104526
104595
  });
104527
104596
 
104528
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/get-schema.mjs
104597
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/get-schema.mjs
104529
104598
  function getSchema(config3) {
104530
104599
  const { indexesByTable, tables } = getAuthTablesWithResolvedIndexes(config3);
104531
104600
  const schema3 = {};
@@ -104562,12 +104631,12 @@ function getSchema(config3) {
104562
104631
  return schema3;
104563
104632
  }
104564
104633
  var init_get_schema = __esm({
104565
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/get-schema.mjs"() {
104634
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/get-schema.mjs"() {
104566
104635
  init_internal();
104567
104636
  }
104568
104637
  });
104569
104638
 
104570
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/get-migration.mjs
104639
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/get-migration.mjs
104571
104640
  function createDatabaseIndexKey(tableName, indexName) {
104572
104641
  return `${getPortableDatabaseIdentifierKey(tableName)}\0${getPortableDatabaseIdentifierKey(indexName)}`;
104573
104642
  }
@@ -104594,7 +104663,7 @@ function toDatabaseIndexMap(indexes) {
104594
104663
  }];
104595
104664
  }));
104596
104665
  }
104597
- async function getDatabaseIndexMap(db, target, tableNames, introspectIndexes) {
104666
+ async function getDatabaseIndexMap(db2, target, tableNames, introspectIndexes) {
104598
104667
  if (introspectIndexes) return toDatabaseIndexMap(await introspectIndexes(tableNames));
104599
104668
  let rows;
104600
104669
  switch (target.type) {
@@ -104611,7 +104680,7 @@ async function getDatabaseIndexMap(db, target, tableNames, introspectIndexes) {
104611
104680
  INNER JOIN pragma_index_list(tables.name) AS index_list
104612
104681
  INNER JOIN pragma_index_info(index_list.name) AS index_info
104613
104682
  WHERE tables.type = 'table'
104614
- `.execute(db)).rows;
104683
+ `.execute(db2)).rows;
104615
104684
  break;
104616
104685
  case "postgres":
104617
104686
  rows = (await sql`
@@ -104639,7 +104708,7 @@ async function getDatabaseIndexMap(db, target, tableNames, introspectIndexes) {
104639
104708
  WHERE table_namespace.nspname = ${target.schema}
104640
104709
  AND table_class.relkind = 'r'
104641
104710
  AND index_column.ordinality <= index_data.indnkeyatts
104642
- `.execute(db)).rows;
104711
+ `.execute(db2)).rows;
104643
104712
  break;
104644
104713
  case "mysql":
104645
104714
  rows = (await sql`
@@ -104653,7 +104722,7 @@ async function getDatabaseIndexMap(db, target, tableNames, introspectIndexes) {
104653
104722
  COALESCE(LOWER(comment) = 'disabled', FALSE) AS isDisabled
104654
104723
  FROM information_schema.statistics
104655
104724
  WHERE table_schema = DATABASE()
104656
- `.execute(db)).rows;
104725
+ `.execute(db2)).rows;
104657
104726
  break;
104658
104727
  case "mssql":
104659
104728
  rows = (await sql`
@@ -104680,7 +104749,7 @@ async function getDatabaseIndexMap(db, target, tableNames, introspectIndexes) {
104680
104749
  WHERE table_schemas.name = ${target.schema}
104681
104750
  AND indexes.name IS NOT NULL
104682
104751
  AND index_columns.key_ordinal > 0
104683
- `.execute(db)).rows;
104752
+ `.execute(db2)).rows;
104684
104753
  break;
104685
104754
  }
104686
104755
  const indexMetadata = /* @__PURE__ */ new Map();
@@ -104717,7 +104786,7 @@ async function getDatabaseIndexMap(db, target, tableNames, introspectIndexes) {
104717
104786
  }
104718
104787
  return toDatabaseIndexMap([...indexMetadata.values()]);
104719
104788
  }
104720
- async function getDatabaseColumnBounds(db, target) {
104789
+ async function getDatabaseColumnBounds(db2, target) {
104721
104790
  let rows;
104722
104791
  switch (target.type) {
104723
104792
  case "postgres":
@@ -104731,7 +104800,7 @@ async function getDatabaseColumnBounds(db, target) {
104731
104800
  character_octet_length AS maxIndexBytes
104732
104801
  FROM information_schema.columns
104733
104802
  WHERE table_schema = DATABASE()
104734
- `.execute(db)).rows;
104803
+ `.execute(db2)).rows;
104735
104804
  break;
104736
104805
  case "mssql":
104737
104806
  rows = (await sql`
@@ -104745,7 +104814,7 @@ async function getDatabaseColumnBounds(db, target) {
104745
104814
  INNER JOIN sys.schemas AS table_schemas
104746
104815
  ON table_schemas.schema_id = tables.schema_id
104747
104816
  WHERE table_schemas.name = ${target.schema}
104748
- `.execute(db)).rows;
104817
+ `.execute(db2)).rows;
104749
104818
  break;
104750
104819
  }
104751
104820
  const bounds = /* @__PURE__ */ new Map();
@@ -104788,8 +104857,8 @@ function hasTimestampColumnDefault(field, dbType) {
104788
104857
  function hasStaticColumnDefault(field) {
104789
104858
  return !(field.unique && field.required === false) && (field.type === "string" || field.type === "number" || field.type === "boolean") && field.defaultValue !== void 0 && field.defaultValue !== null && typeof field.defaultValue !== "function";
104790
104859
  }
104791
- async function tableHasRows(db, dbType, table2) {
104792
- const probe2 = db.selectFrom(table2).select(sql`1`.as("present"));
104860
+ async function tableHasRows(db2, dbType, table2) {
104861
+ const probe2 = db2.selectFrom(table2).select(sql`1`.as("present"));
104793
104862
  return (await (dbType === "mssql" ? probe2.top(1) : probe2.limit(1)).execute()).length > 0;
104794
104863
  }
104795
104864
  function matchType(columnDataType, fieldType, dbType) {
@@ -104809,28 +104878,28 @@ async function getMigrations(config3, { throwOnUnsafe = true } = {}) {
104809
104878
  if (throwOnUnsafe) throw new UnsafeMigrationError(message2);
104810
104879
  unsafeChanges.push(message2);
104811
104880
  };
104812
- let { kysely: db, databaseType: dbType, introspectIndexes, schemaName } = await createKyselyAdapter(config3);
104881
+ let { kysely: db2, databaseType: dbType, introspectIndexes, schemaName } = await createKyselyAdapter(config3);
104813
104882
  if (!dbType) {
104814
104883
  logger3.warn("Could not determine database type, defaulting to sqlite. Please provide a type in the database options to avoid this.");
104815
104884
  dbType = "sqlite";
104816
104885
  }
104817
- if (!db) {
104886
+ if (!db2) {
104818
104887
  logger3.error("Only kysely adapter is supported for migrations. You can use `generate` command to generate the schema, if you're using a different adapter.");
104819
104888
  process.exit(1);
104820
104889
  }
104821
- const allTableMetadata = await db.introspection.getTables();
104890
+ const allTableMetadata = await db2.introspection.getTables();
104822
104891
  let target;
104823
104892
  let tableMetadata = allTableMetadata;
104824
104893
  switch (dbType) {
104825
104894
  case "postgres": {
104826
- const schema3 = schemaName ?? await getPostgresSchema(db);
104895
+ const schema3 = schemaName ?? await getPostgresSchema(db2);
104827
104896
  target = {
104828
104897
  type: "postgres",
104829
104898
  schema: schema3
104830
104899
  };
104831
104900
  logger3.debug(`PostgreSQL migration: Using schema '${schema3}' (${schemaName ? "from database.schemaName" : "from search_path"})`);
104832
104901
  try {
104833
- if (!(await db.introspection.getSchemas()).some(({ name: name2 }) => name2 === schema3)) if (schemaName) logger3.debug(`Schema '${schema3}' does not exist yet. The migration creates it before creating tables.`);
104902
+ if (!(await db2.introspection.getSchemas()).some(({ name: name2 }) => name2 === schema3)) if (schemaName) logger3.debug(`Schema '${schema3}' does not exist yet. The migration creates it before creating tables.`);
104834
104903
  else logger3.warn(`Schema '${schema3}' does not exist. Create it before running migrations or check your database configuration.`);
104835
104904
  } catch (error63) {
104836
104905
  logger3.debug(`Could not verify schema existence: ${error63 instanceof Error ? error63.message : String(error63)}`);
@@ -104840,7 +104909,7 @@ async function getMigrations(config3, { throwOnUnsafe = true } = {}) {
104840
104909
  break;
104841
104910
  }
104842
104911
  case "mssql": {
104843
- const schema3 = await getMssqlSchema(db);
104912
+ const schema3 = await getMssqlSchema(db2);
104844
104913
  target = {
104845
104914
  type: "mssql",
104846
104915
  schema: schema3
@@ -104856,9 +104925,9 @@ async function getMigrations(config3, { throwOnUnsafe = true } = {}) {
104856
104925
  target = { type: "sqlite" };
104857
104926
  break;
104858
104927
  }
104859
- const databaseIndexMap = await getDatabaseIndexMap(db, target, allTableMetadata.map((table2) => table2.name), introspectIndexes);
104860
- const databaseColumnBounds = await getDatabaseColumnBounds(db, target);
104861
- const schemaProblems = diffSchema(toPhysicalSchema(db, betterAuthSchema), toIntrospectedTables(tableMetadata)).filter((finding) => finding.kind === "unexpected-required-column").map((finding) => formatSchemaFinding(finding, "database"));
104928
+ const databaseIndexMap = await getDatabaseIndexMap(db2, target, allTableMetadata.map((table2) => table2.name), introspectIndexes);
104929
+ const databaseColumnBounds = await getDatabaseColumnBounds(db2, target);
104930
+ const schemaProblems = diffSchema(toPhysicalSchema(db2, betterAuthSchema), toIntrospectedTables(tableMetadata)).filter((finding) => finding.kind === "unexpected-required-column").map((finding) => formatSchemaFinding(finding, "database"));
104862
104931
  const toBeCreated = [];
104863
104932
  const toBeAdded = [];
104864
104933
  const toBeAddedIndexes = [];
@@ -104939,7 +105008,7 @@ async function getMigrations(config3, { throwOnUnsafe = true } = {}) {
104939
105008
  });
104940
105009
  }
104941
105010
  const migrations = [];
104942
- if (schemaName && toBeCreated.length > 0) migrations.push(db.schema.createSchema(schemaName).ifNotExists());
105011
+ if (schemaName && toBeCreated.length > 0) migrations.push(db2.schema.createSchema(schemaName).ifNotExists());
104943
105012
  const useUUIDs = config3.advanced?.database?.generateId === "uuid";
104944
105013
  const useNumberId = config3.advanced?.database?.generateId === "serial";
104945
105014
  function getType(field, fieldName, tableIndexStringLength) {
@@ -105047,7 +105116,7 @@ async function getMigrations(config3, { throwOnUnsafe = true } = {}) {
105047
105116
  if (field.required !== false && !timestampDefault && !staticDefault) {
105048
105117
  let populated = populatedTables.get(table2.table);
105049
105118
  if (populated === void 0) {
105050
- populated = await tableHasRows(db, dbType, table2.table);
105119
+ populated = await tableHasRows(db2, dbType, table2.table);
105051
105120
  populatedTables.set(table2.table, populated);
105052
105121
  }
105053
105122
  if (populated) {
@@ -105056,10 +105125,10 @@ async function getMigrations(config3, { throwOnUnsafe = true } = {}) {
105056
105125
  }
105057
105126
  }
105058
105127
  const type2 = getType(field, fieldName, getTableIndexStringLength(table2.table, fieldName));
105059
- const builder = db.schema.alterTable(table2.table);
105128
+ const builder = db2.schema.alterTable(table2.table);
105060
105129
  if (field.index || field.unique) {
105061
105130
  const indexName = getDatabaseFieldIndexName(table2.table, fieldName, field.unique ?? false);
105062
- let indexBuilder = db.schema.createIndex(indexName).on(table2.table).columns([fieldName]);
105131
+ let indexBuilder = db2.schema.createIndex(indexName).on(table2.table).columns([fieldName]);
105063
105132
  if (field.unique) {
105064
105133
  indexBuilder = indexBuilder.unique();
105065
105134
  if (field.required === false && dbType === "mssql") indexBuilder = indexBuilder.where(fieldName, "is not", null);
@@ -105080,7 +105149,7 @@ async function getMigrations(config3, { throwOnUnsafe = true } = {}) {
105080
105149
  }
105081
105150
  if (toBeCreated.length) for (const table2 of toBeCreated) {
105082
105151
  const idType = getType({ type: useNumberId ? "number" : "string" }, "id");
105083
- let dbT = db.schema.createTable(table2.table).addColumn("id", idType, (col) => {
105152
+ let dbT = db2.schema.createTable(table2.table).addColumn("id", idType, (col) => {
105084
105153
  if (useNumberId) {
105085
105154
  if (dbType === "postgres") return col.primaryKey().notNull();
105086
105155
  else if (dbType === "sqlite") return col.primaryKey().notNull();
@@ -105104,14 +105173,14 @@ async function getMigrations(config3, { throwOnUnsafe = true } = {}) {
105104
105173
  return col;
105105
105174
  });
105106
105175
  if (field.index && !field.unique) {
105107
- const builder = db.schema.createIndex(getDatabaseFieldIndexName(table2.table, fieldName, false)).on(table2.table).columns([fieldName]);
105176
+ const builder = db2.schema.createIndex(getDatabaseFieldIndexName(table2.table, fieldName, false)).on(table2.table).columns([fieldName]);
105108
105177
  deferredIndexes.push(builder);
105109
105178
  }
105110
105179
  }
105111
105180
  migrations.push(dbT);
105112
105181
  }
105113
105182
  for (const { table: table2, index: index2, name: name2 } of toBeAddedIndexes) {
105114
- let builder = db.schema.createIndex(name2).on(table2).columns([...index2.columns]);
105183
+ let builder = db2.schema.createIndex(name2).on(table2).columns([...index2.columns]);
105115
105184
  if (index2.unique) builder = builder.unique();
105116
105185
  deferredIndexes.push(builder);
105117
105186
  }
@@ -105138,7 +105207,7 @@ async function getMigrations(config3, { throwOnUnsafe = true } = {}) {
105138
105207
  }
105139
105208
  var map3, UnsafeMigrationError;
105140
105209
  var init_get_migration = __esm({
105141
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/get-migration.mjs"() {
105210
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/get-migration.mjs"() {
105142
105211
  init_get_schema();
105143
105212
  init_db();
105144
105213
  init_env3();
@@ -105234,15 +105303,15 @@ var init_get_migration = __esm({
105234
105303
  }
105235
105304
  });
105236
105305
 
105237
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/constants.mjs
105306
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/constants.mjs
105238
105307
  var DEFAULT_SECRET;
105239
105308
  var init_constants8 = __esm({
105240
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/constants.mjs"() {
105309
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/constants.mjs"() {
105241
105310
  DEFAULT_SECRET = "better-auth-secret-12345678901234567890";
105242
105311
  }
105243
105312
  });
105244
105313
 
105245
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/context/secret-utils.mjs
105314
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/context/secret-utils.mjs
105246
105315
  function estimateEntropy(str2) {
105247
105316
  const unique = new Set(str2).size;
105248
105317
  if (unique === 0) return 0;
@@ -105288,7 +105357,7 @@ function buildSecretConfig(secrets, legacySecret) {
105288
105357
  };
105289
105358
  }
105290
105359
  var init_secret_utils = __esm({
105291
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/context/secret-utils.mjs"() {
105360
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/context/secret-utils.mjs"() {
105292
105361
  init_error2();
105293
105362
  }
105294
105363
  });
@@ -105765,7 +105834,7 @@ var init_node2 = __esm({
105765
105834
  }
105766
105835
  });
105767
105836
 
105768
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/context/create-context.mjs
105837
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/context/create-context.mjs
105769
105838
  function estimateEntropy2(str2) {
105770
105839
  const unique = new Set(str2).size;
105771
105840
  if (unique === 0) return 0;
@@ -105969,7 +106038,7 @@ Most of the features of Better Auth will not work correctly.`);
105969
106038
  return ctx;
105970
106039
  }
105971
106040
  var init_create_context = __esm({
105972
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/context/create-context.mjs"() {
106041
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/context/create-context.mjs"() {
105973
106042
  init_url();
105974
106043
  init_trusted_origins();
105975
106044
  init_store_capabilities();
@@ -105995,10 +106064,10 @@ var init_create_context = __esm({
105995
106064
  }
105996
106065
  });
105997
106066
 
105998
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/context/init.mjs
106067
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/context/init.mjs
105999
106068
  var init2;
106000
106069
  var init_init = __esm({
106001
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/context/init.mjs"() {
106070
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/context/init.mjs"() {
106002
106071
  init_adapter_kysely();
106003
106072
  init_get_migration();
106004
106073
  init_create_context();
@@ -106018,10 +106087,10 @@ var init_init = __esm({
106018
106087
  }
106019
106088
  });
106020
106089
 
106021
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/auth/base.mjs
106090
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/auth/base.mjs
106022
106091
  var createBetterAuth;
106023
106092
  var init_base = __esm({
106024
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/auth/base.mjs"() {
106093
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/auth/base.mjs"() {
106025
106094
  init_url();
106026
106095
  init_helpers();
106027
106096
  init_api4();
@@ -106088,10 +106157,10 @@ var init_base = __esm({
106088
106157
  }
106089
106158
  });
106090
106159
 
106091
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/auth/full.mjs
106160
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/auth/full.mjs
106092
106161
  var betterAuth;
106093
106162
  var init_full = __esm({
106094
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/auth/full.mjs"() {
106163
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/auth/full.mjs"() {
106095
106164
  init_init();
106096
106165
  init_base();
106097
106166
  betterAuth = (options) => {
@@ -106106,9 +106175,9 @@ var init_dist12 = __esm({
106106
106175
  }
106107
106176
  });
106108
106177
 
106109
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/index.mjs
106178
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/index.mjs
106110
106179
  var init_dist13 = __esm({
106111
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/index.mjs"() {
106180
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/index.mjs"() {
106112
106181
  init_full();
106113
106182
  init_dist12();
106114
106183
  init_db();
@@ -108375,18 +108444,18 @@ var init_dist14 = __esm({
108375
108444
  init_env3();
108376
108445
  init_error2();
108377
108446
  init_drizzle_orm();
108378
- drizzleAdapter = (db, config3) => {
108447
+ drizzleAdapter = (db2, config3) => {
108379
108448
  let lazyOptions = null;
108380
108449
  let mysqlNoIdWarned = false;
108381
108450
  let relationKeysByModel;
108382
- const getRelationKeysByModel = () => relationKeysByModel ??= buildRelationKeysByModel(db._?.schema);
108383
- const createCustomAdapter = (db2, inTransaction = false) => ({ getFieldName, getDefaultFieldName, getDefaultModelName, options, schema: baSchema }) => {
108451
+ const getRelationKeysByModel = () => relationKeysByModel ??= buildRelationKeysByModel(db2._?.schema);
108452
+ const createCustomAdapter = (db3, inTransaction = false) => ({ getFieldName, getDefaultFieldName, getDefaultModelName, options, schema: baSchema }) => {
108384
108453
  if (config3.provider === "mysql" && options.advanced?.database?.generateId === false && !mysqlNoIdWarned) {
108385
108454
  mysqlNoIdWarned = true;
108386
108455
  logger2.warn(`[Drizzle Adapter] MySQL does not support INSERT...RETURNING. With generateId set to false, the adapter uses best-effort fallback strategies (unique columns, full-field match) to retrieve inserted rows. For reliable behavior, use Better Auth's default ID generation, a custom generateId function, or generateId: "serial" for auto-increment.`);
108387
108456
  }
108388
108457
  function getSchema2(model) {
108389
- const schema3 = config3.schema || db2._.fullSchema;
108458
+ const schema3 = config3.schema || db3._.fullSchema;
108390
108459
  if (!schema3) throw new BetterAuthError("Drizzle adapter failed to initialize. Schema not found. Please provide a schema object in the adapter options object.");
108391
108460
  const schemaModel = schema3[model];
108392
108461
  if (!schemaModel) throw new BetterAuthError(`[# Drizzle Adapter]: The model "${model}" was not found in the schema object. Please pass the schema directly to the adapter options.`);
@@ -108405,7 +108474,7 @@ var init_dist14 = __esm({
108405
108474
  };
108406
108475
  return w2;
108407
108476
  }), model, modelKey);
108408
- return (await db2.select().from(table2).where(...clause))[0];
108477
+ return (await db3.select().from(table2).where(...clause))[0];
108409
108478
  }
108410
108479
  const fetchInserted = async (tx) => {
108411
108480
  const builderId = builderVal?.[0]?.id?.value;
@@ -108443,7 +108512,7 @@ var init_dist14 = __esm({
108443
108512
  logger2.warn(`[Drizzle Adapter] Unable to safely identify the inserted "${model}" row on MySQL. Enable Better Auth ID generation or use generateId: "serial" for reliable behavior.`);
108444
108513
  return null;
108445
108514
  };
108446
- return inTransaction ? fetchInserted(db2) : db2.transaction(fetchInserted);
108515
+ return inTransaction ? fetchInserted(db3) : db3.transaction(fetchInserted);
108447
108516
  };
108448
108517
  function convertWhereClause(where, model, modelKey) {
108449
108518
  const schemaModel = getSchema2(model);
@@ -108595,18 +108664,18 @@ var init_dist14 = __esm({
108595
108664
  }
108596
108665
  }
108597
108666
  function getQueryModel(model) {
108598
- if (!db2.query) return null;
108599
- if (db2.query[model]) return model;
108667
+ if (!db3.query) return null;
108668
+ if (db3.query[model]) return model;
108600
108669
  if (config3.usePlural) {
108601
108670
  const plural3 = `${model}s`;
108602
- if (db2.query[plural3]) return plural3;
108671
+ if (db3.query[plural3]) return plural3;
108603
108672
  }
108604
108673
  if (config3.schema) {
108605
108674
  const targetTable = config3.schema[model];
108606
108675
  if (targetTable) {
108607
- const fullSchema = db2._.fullSchema;
108676
+ const fullSchema = db3._.fullSchema;
108608
108677
  if (fullSchema) {
108609
- for (const key of Object.keys(db2.query)) if (fullSchema[key] === targetTable) return key;
108678
+ for (const key of Object.keys(db3.query)) if (fullSchema[key] === targetTable) return key;
108610
108679
  }
108611
108680
  }
108612
108681
  }
@@ -108628,14 +108697,14 @@ var init_dist14 = __esm({
108628
108697
  async create({ model, modelKey = model, data: values2 }) {
108629
108698
  const table2 = getSchema2(model);
108630
108699
  checkMissingFields(table2, modelKey, values2);
108631
- return await withReturning(model, modelKey, db2.insert(table2).values(values2), values2);
108700
+ return await withReturning(model, modelKey, db3.insert(table2).values(values2), values2);
108632
108701
  },
108633
108702
  async findOne({ model, modelKey = model, where, select: select2, join: join62 }) {
108634
108703
  const table2 = getSchema2(model);
108635
108704
  const clause = convertWhereClause(where, model, modelKey);
108636
108705
  if (join62) {
108637
108706
  const queryModel = getQueryModel(model);
108638
- if (!db2.query || !queryModel) {
108707
+ if (!db3.query || !queryModel) {
108639
108708
  logger2.error(`[# Drizzle Adapter]: The model "${model}" was not found in the query object. Please update your Drizzle schema to include relations or re-generate using "npx auth@latest generate".`);
108640
108709
  logger2.info("Falling back to regular query");
108641
108710
  } else {
@@ -108654,7 +108723,7 @@ var init_dist14 = __esm({
108654
108723
  target: joinModel
108655
108724
  });
108656
108725
  }
108657
- const res2 = await db2.query[queryModel].findFirst({
108726
+ const res2 = await db3.query[queryModel].findFirst({
108658
108727
  where: clause[0],
108659
108728
  columns: select2?.length && select2.length > 0 ? select2.reduce((acc, field) => {
108660
108729
  acc[getFieldName({
@@ -108672,7 +108741,7 @@ var init_dist14 = __esm({
108672
108741
  return res2;
108673
108742
  }
108674
108743
  }
108675
- const res = await db2.select(select2?.length && select2.length > 0 ? select2.reduce((acc, field) => {
108744
+ const res = await db3.select(select2?.length && select2.length > 0 ? select2.reduce((acc, field) => {
108676
108745
  const fieldName = getFieldName({
108677
108746
  model: modelKey,
108678
108747
  field
@@ -108691,7 +108760,7 @@ var init_dist14 = __esm({
108691
108760
  const sortFn = sortBy?.direction === "desc" ? desc : asc;
108692
108761
  if (join62) {
108693
108762
  const queryModel = getQueryModel(model);
108694
- if (!db2.query || !queryModel) {
108763
+ if (!db3.query || !queryModel) {
108695
108764
  logger2.error(`[# Drizzle Adapter]: The model "${model}" was not found in the query object. Please update your Drizzle schema to include relations or re-generate using "npx auth@latest generate".`);
108696
108765
  logger2.info("Falling back to regular query");
108697
108766
  } else {
@@ -108715,7 +108784,7 @@ var init_dist14 = __esm({
108715
108784
  model: modelKey,
108716
108785
  field: sortBy?.field
108717
108786
  })])];
108718
- const res = await db2.query[queryModel].findMany({
108787
+ const res = await db3.query[queryModel].findMany({
108719
108788
  where: clause[0],
108720
108789
  with: includes,
108721
108790
  columns: select2?.length && select2.length > 0 ? select2.reduce((acc, field) => {
@@ -108736,7 +108805,7 @@ var init_dist14 = __esm({
108736
108805
  return res;
108737
108806
  }
108738
108807
  }
108739
- let builder = db2.select(select2?.length && select2.length > 0 ? select2.reduce((acc, field) => {
108808
+ let builder = db3.select(select2?.length && select2.length > 0 ? select2.reduce((acc, field) => {
108740
108809
  const fieldName = getFieldName({
108741
108810
  model: modelKey,
108742
108811
  field
@@ -108759,17 +108828,17 @@ var init_dist14 = __esm({
108759
108828
  async count({ model, modelKey = model, where }) {
108760
108829
  const table2 = getSchema2(model);
108761
108830
  const clause = where ? convertWhereClause(where, model, modelKey) : [];
108762
- return (await db2.select({ count: count() }).from(table2).where(...clause))[0].count;
108831
+ return (await db3.select({ count: count() }).from(table2).where(...clause))[0].count;
108763
108832
  },
108764
108833
  async update({ model, modelKey = model, where, update: values2 }) {
108765
108834
  const table2 = getSchema2(model);
108766
108835
  const clause = convertWhereClause(where, model, modelKey);
108767
- return await withReturning(model, modelKey, db2.update(table2).set(values2).where(...clause), values2, where);
108836
+ return await withReturning(model, modelKey, db3.update(table2).set(values2).where(...clause), values2, where);
108768
108837
  },
108769
108838
  async updateMany({ model, modelKey = model, where, update: values2 }) {
108770
108839
  const table2 = getSchema2(model);
108771
108840
  const clause = convertWhereClause(where, model, modelKey);
108772
- return getAffectedRowCount(await db2.update(table2).set(values2).where(...clause), "updateMany", {
108841
+ return getAffectedRowCount(await db3.update(table2).set(values2).where(...clause), "updateMany", {
108773
108842
  model,
108774
108843
  where
108775
108844
  });
@@ -108777,12 +108846,12 @@ var init_dist14 = __esm({
108777
108846
  async delete({ model, modelKey = model, where }) {
108778
108847
  const table2 = getSchema2(model);
108779
108848
  const clause = convertWhereClause(where, model, modelKey);
108780
- return await db2.delete(table2).where(...clause);
108849
+ return await db3.delete(table2).where(...clause);
108781
108850
  },
108782
108851
  async deleteMany({ model, modelKey = model, where }) {
108783
108852
  const table2 = getSchema2(model);
108784
108853
  const clause = convertWhereClause(where, model, modelKey);
108785
- return getAffectedRowCount(await db2.delete(table2).where(...clause), "deleteMany", {
108854
+ return getAffectedRowCount(await db3.delete(table2).where(...clause), "deleteMany", {
108786
108855
  model,
108787
108856
  where
108788
108857
  });
@@ -108806,11 +108875,11 @@ var init_dist14 = __esm({
108806
108875
  where
108807
108876
  }) > 0 ? target : null;
108808
108877
  };
108809
- return inTransaction ? claimFromTransaction(db2) : db2.transaction(claimFromTransaction);
108878
+ return inTransaction ? claimFromTransaction(db3) : db3.transaction(claimFromTransaction);
108810
108879
  }
108811
108880
  if (!idColumn) return null;
108812
- const targetIds = db2.select({ id: idColumn }).from(table2).where(...clause).limit(1);
108813
- return (await db2.delete(table2).where(inArray(idColumn, targetIds)).returning())[0] ?? null;
108881
+ const targetIds = db3.select({ id: idColumn }).from(table2).where(...clause).limit(1);
108882
+ return (await db3.delete(table2).where(inArray(idColumn, targetIds)).returning())[0] ?? null;
108814
108883
  },
108815
108884
  async incrementOne({ model, modelKey = model, where, increment, set: set3 }) {
108816
108885
  const table2 = getSchema2(model);
@@ -108847,11 +108916,11 @@ var init_dist14 = __esm({
108847
108916
  await tx.update(table2).set(assignments).where(eq(idColumn, targetId)).execute();
108848
108917
  return (await tx.select().from(table2).where(eq(idColumn, targetId)).limit(1).execute())[0] ?? null;
108849
108918
  };
108850
- return inTransaction ? mutateInTransaction(db2) : db2.transaction(mutateInTransaction);
108919
+ return inTransaction ? mutateInTransaction(db3) : db3.transaction(mutateInTransaction);
108851
108920
  }
108852
108921
  if (!idColumn) return null;
108853
- const targetIds = db2.select({ id: idColumn }).from(table2).where(...clause).limit(1);
108854
- return (await db2.update(table2).set(assignments).where(inArray(idColumn, targetIds)).returning())[0] ?? null;
108922
+ const targetIds = db3.select({ id: idColumn }).from(table2).where(...clause).limit(1);
108923
+ return (await db3.update(table2).set(assignments).where(inArray(idColumn, targetIds)).returning())[0] ?? null;
108855
108924
  },
108856
108925
  options: config3
108857
108926
  };
@@ -108873,7 +108942,7 @@ var init_dist14 = __esm({
108873
108942
  }
108874
108943
  return data;
108875
108944
  },
108876
- transaction: config3.transaction ?? false ? (cb) => db.transaction((tx) => {
108945
+ transaction: config3.transaction ?? false ? (cb) => db2.transaction((tx) => {
108877
108946
  return cb(createAdapterFactory({
108878
108947
  config: {
108879
108948
  ...adapterOptions.config,
@@ -108883,38 +108952,38 @@ var init_dist14 = __esm({
108883
108952
  })(lazyOptions));
108884
108953
  }) : false
108885
108954
  },
108886
- adapter: createCustomAdapter(db)
108955
+ adapter: createCustomAdapter(db2)
108887
108956
  };
108888
108957
  const adapter = createAdapterFactory(adapterOptions);
108889
108958
  return (options) => {
108890
108959
  lazyOptions = options;
108891
108960
  const instance = adapter(options);
108892
- registerSchemaCheck(instance, createSchemaCheck(() => findDrizzleSchemaProblems(config3.schema ?? db._?.fullSchema ?? {}, options, config3.usePlural), "drizzle"), { runtimeEnabled: checksSchema(options) });
108961
+ registerSchemaCheck(instance, createSchemaCheck(() => findDrizzleSchemaProblems(config3.schema ?? db2._?.fullSchema ?? {}, options, config3.usePlural), "drizzle"), { runtimeEnabled: checksSchema(options) });
108893
108962
  return instance;
108894
108963
  };
108895
108964
  };
108896
108965
  }
108897
108966
  });
108898
108967
 
108899
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/adapters/drizzle-adapter/index.mjs
108968
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/adapters/drizzle-adapter/index.mjs
108900
108969
  var init_drizzle_adapter = __esm({
108901
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/adapters/drizzle-adapter/index.mjs"() {
108970
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/adapters/drizzle-adapter/index.mjs"() {
108902
108971
  init_dist14();
108903
108972
  }
108904
108973
  });
108905
108974
 
108906
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/package.mjs
108975
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/package.mjs
108907
108976
  var version3;
108908
108977
  var init_package = __esm({
108909
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/package.mjs"() {
108978
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/package.mjs"() {
108910
108979
  version3 = "1.7.6";
108911
108980
  }
108912
108981
  });
108913
108982
 
108914
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/version.mjs
108983
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/version.mjs
108915
108984
  var PACKAGE_VERSION;
108916
108985
  var init_version4 = __esm({
108917
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/version.mjs"() {
108986
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/version.mjs"() {
108918
108987
  init_package();
108919
108988
  PACKAGE_VERSION = version3;
108920
108989
  }
@@ -110435,6 +110504,113 @@ var init_directory = __esm({
110435
110504
  }
110436
110505
  });
110437
110506
 
110507
+ // ../cloud-api/dist/step-up.js
110508
+ function originMatchesRpId(statement) {
110509
+ return new URL(statement.origin).hostname === statement.rpId;
110510
+ }
110511
+ function expiresAfterIssue(statement) {
110512
+ return Date.parse(statement.expiresAt) > Date.parse(statement.issuedAt);
110513
+ }
110514
+ var STEP_UP_STATEMENT_MAX_BYTES, STEP_UP_STATEMENT_MAX_BASE64URL_LENGTH, STEP_UP_MAX_CREDENTIALS, base64url3, StepUpChallengeIdSchema, ComputerIdSchema, NO_CONTROL, INVISIBLE, displayText, SessionIdSchema, ToolCallIdSchema, Sha256HexSchema, NonceSchema, InstantSchema, CredentialIdSchema, RpIdSchema, OriginSchema, StepUpLoopbackReturnToSchema, STEP_UP_APPROVAL_STATEMENT_TYPE, STEP_UP_ENROL_STATEMENT_TYPE, StepUpStatementV1Schema, PasskeyEnrolStatementV1Schema, StepUpAnyStatementSchema, StepUpAssertionSchema, StepUpMessageSchema, LONE_SURROGATE;
110515
+ var init_step_up = __esm({
110516
+ "../cloud-api/dist/step-up.js"() {
110517
+ "use strict";
110518
+ init_zod();
110519
+ init_hubs();
110520
+ STEP_UP_STATEMENT_MAX_BYTES = 262144;
110521
+ STEP_UP_STATEMENT_MAX_BASE64URL_LENGTH = Math.ceil(STEP_UP_STATEMENT_MAX_BYTES * 4 / 3);
110522
+ STEP_UP_MAX_CREDENTIALS = 16;
110523
+ base64url3 = (max2) => external_exports.string().min(1).max(max2).regex(/^[A-Za-z0-9_-]+$/);
110524
+ StepUpChallengeIdSchema = external_exports.string().min(1).max(64).regex(/^[\w.:-]+$/).describe("The id of one challenge the computer issued. Letters, digits and _ . : - only.");
110525
+ ComputerIdSchema = StepUpChallengeIdSchema;
110526
+ NO_CONTROL = /^[^\u0000-\u001f\u007f]*$/;
110527
+ INVISIBLE = /[\p{Cf}\u2028\u2029]/u;
110528
+ displayText = (max2) => external_exports.string().min(1).max(max2).regex(NO_CONTROL).refine((text3) => text3.trim() === text3, "no leading or trailing whitespace").refine((text3) => !INVISIBLE.test(text3), "no invisible characters");
110529
+ SessionIdSchema = external_exports.string().regex(/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/);
110530
+ ToolCallIdSchema = external_exports.string().min(1).max(256).regex(/^[\w.:-]+$/);
110531
+ Sha256HexSchema = external_exports.string().regex(/^[0-9a-f]{64}$/);
110532
+ NonceSchema = external_exports.string().length(43).regex(/^[A-Za-z0-9_-]+$/);
110533
+ InstantSchema = external_exports.iso.datetime({ precision: 3 });
110534
+ CredentialIdSchema = base64url3(1400);
110535
+ RpIdSchema = external_exports.string().max(253).regex(/^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/);
110536
+ OriginSchema = HttpsOriginSchema.max(256);
110537
+ StepUpLoopbackReturnToSchema = external_exports.string().max(2048).regex(/^http:\/\/(127\.0\.0\.1|localhost):[1-9][0-9]{0,4}\//, "must be a loopback http page").refine((value) => {
110538
+ try {
110539
+ const url2 = new URL(value);
110540
+ return url2.protocol === "http:" && (url2.hostname === "127.0.0.1" || url2.hostname === "localhost") && url2.port !== "" && url2.username === "" && url2.password === "" && url2.hash === "" && url2.href === value;
110541
+ } catch {
110542
+ return false;
110543
+ }
110544
+ }, "must be a loopback http page with an explicit port, written canonically").describe("A page on the computer itself: plain http to its loopback address, explicit port.");
110545
+ STEP_UP_APPROVAL_STATEMENT_TYPE = "dorkos.relay.approval.v1";
110546
+ STEP_UP_ENROL_STATEMENT_TYPE = "dorkos.relay.passkey-enrol.v1";
110547
+ StepUpStatementV1Schema = external_exports.strictObject({
110548
+ t: external_exports.literal(STEP_UP_APPROVAL_STATEMENT_TYPE),
110549
+ challengeId: StepUpChallengeIdSchema,
110550
+ computerId: ComputerIdSchema,
110551
+ computerName: displayText(64),
110552
+ hubOrigin: OriginSchema,
110553
+ sessionId: SessionIdSchema,
110554
+ toolCallId: ToolCallIdSchema,
110555
+ decision: external_exports.enum(["approve", "deny"]),
110556
+ toolName: displayText(256),
110557
+ displayName: displayText(256).optional(),
110558
+ input: external_exports.json(),
110559
+ inputSha256: Sha256HexSchema,
110560
+ nonce: NonceSchema,
110561
+ issuedAt: InstantSchema,
110562
+ expiresAt: InstantSchema,
110563
+ rpId: RpIdSchema,
110564
+ origin: OriginSchema,
110565
+ credentialIds: external_exports.array(CredentialIdSchema).min(1).max(STEP_UP_MAX_CREDENTIALS)
110566
+ }).refine(originMatchesRpId, "the origin`s host must be the relying party id").refine(expiresAfterIssue, "a statement must expire after it was issued").describe("What the owner signs to approve or deny one tool call from the web.");
110567
+ PasskeyEnrolStatementV1Schema = external_exports.strictObject({
110568
+ t: external_exports.literal(STEP_UP_ENROL_STATEMENT_TYPE),
110569
+ challengeId: StepUpChallengeIdSchema,
110570
+ computerId: ComputerIdSchema,
110571
+ computerName: displayText(64),
110572
+ accountId: StepUpChallengeIdSchema,
110573
+ userHandle: base64url3(128),
110574
+ nonce: NonceSchema,
110575
+ issuedAt: InstantSchema,
110576
+ expiresAt: InstantSchema,
110577
+ rpId: RpIdSchema,
110578
+ origin: OriginSchema,
110579
+ returnTo: StepUpLoopbackReturnToSchema,
110580
+ excludeCredentialIds: external_exports.array(CredentialIdSchema).max(STEP_UP_MAX_CREDENTIALS)
110581
+ }).refine(originMatchesRpId, "the origin`s host must be the relying party id").refine(expiresAfterIssue, "a statement must expire after it was issued").describe("What the owner signs, at the computer, to add an approvals passkey.");
110582
+ StepUpAnyStatementSchema = external_exports.discriminatedUnion("t", [StepUpStatementV1Schema, PasskeyEnrolStatementV1Schema]).describe("An approval statement or a passkey enrol statement, told apart by `t`.");
110583
+ StepUpAssertionSchema = external_exports.strictObject({
110584
+ /** The challenge the computer issued, by its id. */
110585
+ challengeId: StepUpChallengeIdSchema,
110586
+ credentialId: CredentialIdSchema,
110587
+ clientDataJSON: base64url3(4096),
110588
+ authenticatorData: base64url3(1024),
110589
+ signature: base64url3(512),
110590
+ userHandle: base64url3(128).optional()
110591
+ }).describe("A WebAuthn assertion over a challenge the computer issued, binary fields base64url.");
110592
+ StepUpMessageSchema = external_exports.discriminatedUnion("type", [
110593
+ external_exports.strictObject({ type: external_exports.literal("dorkos.stepup.ready") }),
110594
+ external_exports.strictObject({
110595
+ type: external_exports.literal("dorkos.stepup.request"),
110596
+ v: external_exports.literal(1),
110597
+ statement: base64url3(STEP_UP_STATEMENT_MAX_BASE64URL_LENGTH)
110598
+ }),
110599
+ external_exports.strictObject({
110600
+ type: external_exports.literal("dorkos.stepup.result"),
110601
+ challengeId: StepUpChallengeIdSchema,
110602
+ assertion: StepUpAssertionSchema
110603
+ }).refine((message2) => message2.assertion.challengeId === message2.challengeId, "the assertion must be for the same challenge"),
110604
+ external_exports.strictObject({
110605
+ type: external_exports.literal("dorkos.stepup.cancel"),
110606
+ challengeId: StepUpChallengeIdSchema,
110607
+ reason: external_exports.enum(["dismissed", "expired", "not-allowed"])
110608
+ })
110609
+ ]).describe("A message between the hub`s page and the approve page, told apart by `type`.");
110610
+ LONE_SURROGATE = new RegExp("\\p{Cs}", "u");
110611
+ }
110612
+ });
110613
+
110438
110614
  // ../cloud-api/dist/index.js
110439
110615
  var init_dist15 = __esm({
110440
110616
  "../cloud-api/dist/index.js"() {
@@ -110453,6 +110629,7 @@ var init_dist15 = __esm({
110453
110629
  init_communities();
110454
110630
  init_hubs();
110455
110631
  init_directory();
110632
+ init_step_up();
110456
110633
  }
110457
110634
  });
110458
110635
 
@@ -110505,10 +110682,10 @@ var init_desktop_sign_in = __esm({
110505
110682
  }
110506
110683
  });
110507
110684
 
110508
- // ../../node_modules/.pnpm/@better-auth+api-key@1.7.6_@better-auth+core@1.7.6_@better-auth+utils@0.5.0_@better-fet_614509f08999547ecfbbff9e687b5da6/node_modules/@better-auth/api-key/dist/version-BjgKH8I0.mjs
110685
+ // ../../node_modules/.pnpm/@better-auth+api-key@1.7.6_@better-auth+core@1.7.6_@better-auth+utils@0.5.0_@better-fet_9f33cd4e6a3de2100016969b8e81afec/node_modules/@better-auth/api-key/dist/version-BjgKH8I0.mjs
110509
110686
  var API_KEY_ERROR_CODES, PACKAGE_VERSION2;
110510
110687
  var init_version_BjgKH8I0 = __esm({
110511
- "../../node_modules/.pnpm/@better-auth+api-key@1.7.6_@better-auth+core@1.7.6_@better-auth+utils@0.5.0_@better-fet_614509f08999547ecfbbff9e687b5da6/node_modules/@better-auth/api-key/dist/version-BjgKH8I0.mjs"() {
110688
+ "../../node_modules/.pnpm/@better-auth+api-key@1.7.6_@better-auth+core@1.7.6_@better-auth+utils@0.5.0_@better-fet_9f33cd4e6a3de2100016969b8e81afec/node_modules/@better-auth/api-key/dist/version-BjgKH8I0.mjs"() {
110512
110689
  init_error_codes();
110513
110690
  API_KEY_ERROR_CODES = defineErrorCodes({
110514
110691
  INVALID_METADATA_TYPE: "metadata must be an object or undefined",
@@ -110547,10 +110724,10 @@ var init_version_BjgKH8I0 = __esm({
110547
110724
  }
110548
110725
  });
110549
110726
 
110550
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/_virtual/_rolldown/runtime.mjs
110727
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/_virtual/_rolldown/runtime.mjs
110551
110728
  var __defProp2, __getOwnPropDesc2, __getOwnPropNames2, __hasOwnProp2, __exportAll, __copyProps2, __reExport;
110552
110729
  var init_runtime = __esm({
110553
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/_virtual/_rolldown/runtime.mjs"() {
110730
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/_virtual/_rolldown/runtime.mjs"() {
110554
110731
  __defProp2 = Object.defineProperty;
110555
110732
  __getOwnPropDesc2 = Object.getOwnPropertyDescriptor;
110556
110733
  __getOwnPropNames2 = Object.getOwnPropertyNames;
@@ -110578,7 +110755,7 @@ var init_runtime = __esm({
110578
110755
  }
110579
110756
  });
110580
110757
 
110581
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/field-converter.mjs
110758
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/field-converter.mjs
110582
110759
  function convertToDB(fields, values2) {
110583
110760
  const result2 = values2.id ? { id: values2.id } : {};
110584
110761
  for (const key in fields) {
@@ -110596,11 +110773,11 @@ function convertFromDB(fields, values2) {
110596
110773
  return result2;
110597
110774
  }
110598
110775
  var init_field_converter = __esm({
110599
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/field-converter.mjs"() {
110776
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/field-converter.mjs"() {
110600
110777
  }
110601
110778
  });
110602
110779
 
110603
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/revoke-unproven-account-access.mjs
110780
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/revoke-unproven-account-access.mjs
110604
110781
  async function waitForCleanupLock(ctx, identifier) {
110605
110782
  const deadline = Date.now() + cleanupLockWaitMs;
110606
110783
  while (Date.now() < deadline) {
@@ -110640,7 +110817,7 @@ async function revokeUnprovenAccountAccess(ctx, userId) {
110640
110817
  }
110641
110818
  var cleanupLockExpiresInMs, cleanupLockWaitMs, cleanupLockPollMs, cleanupLockIdentifier;
110642
110819
  var init_revoke_unproven_account_access = __esm({
110643
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/revoke-unproven-account-access.mjs"() {
110820
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/revoke-unproven-account-access.mjs"() {
110644
110821
  init_error2();
110645
110822
  cleanupLockExpiresInMs = 5e3;
110646
110823
  cleanupLockWaitMs = 2e3;
@@ -110649,7 +110826,7 @@ var init_revoke_unproven_account_access = __esm({
110649
110826
  }
110650
110827
  });
110651
110828
 
110652
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/to-zod.mjs
110829
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/to-zod.mjs
110653
110830
  function toZodSchema({ fields, isClientSide }) {
110654
110831
  const zodFields = Object.keys(fields).reduce((acc, key) => {
110655
110832
  const field = fields[key];
@@ -110670,15 +110847,15 @@ function toZodSchema({ fields, isClientSide }) {
110670
110847
  return object(zodFields);
110671
110848
  }
110672
110849
  var init_to_zod = __esm({
110673
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/to-zod.mjs"() {
110850
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/to-zod.mjs"() {
110674
110851
  init_zod();
110675
110852
  }
110676
110853
  });
110677
110854
 
110678
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/index.mjs
110855
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/index.mjs
110679
110856
  var db_exports2;
110680
110857
  var init_db3 = __esm({
110681
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/db/index.mjs"() {
110858
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/db/index.mjs"() {
110682
110859
  init_runtime();
110683
110860
  init_get_schema();
110684
110861
  init_schema2();
@@ -110745,7 +110922,7 @@ var init_async = __esm({
110745
110922
  }
110746
110923
  });
110747
110924
 
110748
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/access/access.mjs
110925
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/access/access.mjs
110749
110926
  function unknownResourceResponse(requestedResource) {
110750
110927
  return {
110751
110928
  success: false,
@@ -110821,19 +110998,19 @@ function createAccessControl(s2) {
110821
110998
  };
110822
110999
  }
110823
111000
  var init_access = __esm({
110824
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/access/access.mjs"() {
111001
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/access/access.mjs"() {
110825
111002
  init_error2();
110826
111003
  }
110827
111004
  });
110828
111005
 
110829
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/access/index.mjs
111006
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/access/index.mjs
110830
111007
  var init_access2 = __esm({
110831
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/access/index.mjs"() {
111008
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/access/index.mjs"() {
110832
111009
  init_access();
110833
111010
  }
110834
111011
  });
110835
111012
 
110836
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/client/parser.mjs
111013
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/client/parser.mjs
110837
111014
  function isValidDate(date5) {
110838
111015
  return date5 instanceof Date && !isNaN(date5.getTime());
110839
111016
  }
@@ -110886,7 +111063,7 @@ function parseJSON(value, options = { strict: true }) {
110886
111063
  }
110887
111064
  var PROTO_POLLUTION_PATTERNS, JSON_SIGNATURE, SPECIAL_VALUES, ISO_DATE_REGEX;
110888
111065
  var init_parser2 = __esm({
110889
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/client/parser.mjs"() {
111066
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/client/parser.mjs"() {
110890
111067
  PROTO_POLLUTION_PATTERNS = {
110891
111068
  proto: /"(?:_|\\u0{2}5[Ff]){2}(?:p|\\u0{2}70)(?:r|\\u0{2}72)(?:o|\\u0{2}6[Ff])(?:t|\\u0{2}74)(?:o|\\u0{2}6[Ff])(?:_|\\u0{2}5[Ff]){2}"\s*:/,
110892
111069
  constructor: /"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/,
@@ -110907,14 +111084,14 @@ var init_parser2 = __esm({
110907
111084
  }
110908
111085
  });
110909
111086
 
110910
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/client/index.mjs
111087
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/client/index.mjs
110911
111088
  var init_client = __esm({
110912
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/client/index.mjs"() {
111089
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/client/index.mjs"() {
110913
111090
  init_parser2();
110914
111091
  }
110915
111092
  });
110916
111093
 
110917
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/adapter.mjs
111094
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/adapter.mjs
110918
111095
  async function computeTeamMembershipKey(data) {
110919
111096
  const digest2 = await createHash("SHA-256").digest(new TextEncoder().encode(JSON.stringify([data.teamId, data.userId])));
110920
111097
  return base64Url.encode(new Uint8Array(digest2), { padding: false });
@@ -111033,7 +111210,7 @@ function stripTeamMembershipKeys(members2) {
111033
111210
  }
111034
111211
  var getOrgAdapter;
111035
111212
  var init_adapter2 = __esm({
111036
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/adapter.mjs"() {
111213
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/adapter.mjs"() {
111037
111214
  init_date();
111038
111215
  init_parser2();
111039
111216
  init_context2();
@@ -111731,10 +111908,10 @@ var init_adapter2 = __esm({
111731
111908
  }
111732
111909
  });
111733
111910
 
111734
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/access/statement.mjs
111911
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/access/statement.mjs
111735
111912
  var defaultStatements, defaultAc, adminAc, ownerAc, memberAc, defaultRoles;
111736
111913
  var init_statement = __esm({
111737
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/access/statement.mjs"() {
111914
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/access/statement.mjs"() {
111738
111915
  init_access();
111739
111916
  defaultStatements = {
111740
111917
  organization: ["update", "delete"],
@@ -111812,10 +111989,10 @@ var init_statement = __esm({
111812
111989
  }
111813
111990
  });
111814
111991
 
111815
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/permission.mjs
111992
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/permission.mjs
111816
111993
  var hasPermissionFn, cacheAllRoles;
111817
111994
  var init_permission = __esm({
111818
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/permission.mjs"() {
111995
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/permission.mjs"() {
111819
111996
  hasPermissionFn = (input4, acRoles) => {
111820
111997
  if (!input4.permissions) return false;
111821
111998
  const roles = input4.role.split(",");
@@ -111830,10 +112007,10 @@ var init_permission = __esm({
111830
112007
  }
111831
112008
  });
111832
112009
 
111833
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/has-permission.mjs
112010
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/has-permission.mjs
111834
112011
  var rolePermissionsSchema, hasPermission;
111835
112012
  var init_has_permission = __esm({
111836
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/has-permission.mjs"() {
112013
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/has-permission.mjs"() {
111837
112014
  init_api4();
111838
112015
  init_statement();
111839
112016
  init_permission();
@@ -111868,10 +112045,10 @@ var init_has_permission = __esm({
111868
112045
  }
111869
112046
  });
111870
112047
 
111871
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/error-codes.mjs
112048
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/error-codes.mjs
111872
112049
  var ORGANIZATION_ERROR_CODES;
111873
112050
  var init_error_codes2 = __esm({
111874
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/error-codes.mjs"() {
112051
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/error-codes.mjs"() {
111875
112052
  init_error_codes();
111876
112053
  ORGANIZATION_ERROR_CODES = defineErrorCodes({
111877
112054
  YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_ORGANIZATION: "You are not allowed to create a new organization",
@@ -111937,10 +112114,10 @@ var init_error_codes2 = __esm({
111937
112114
  }
111938
112115
  });
111939
112116
 
111940
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/shim.mjs
112117
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/shim.mjs
111941
112118
  var shimContext;
111942
112119
  var init_shim = __esm({
111943
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/utils/shim.mjs"() {
112120
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/utils/shim.mjs"() {
111944
112121
  shimContext = (originalObject, newContext) => {
111945
112122
  const shimmedObj = {};
111946
112123
  for (const [key, value] of Object.entries(originalObject)) {
@@ -111963,10 +112140,10 @@ var init_shim = __esm({
111963
112140
  }
111964
112141
  });
111965
112142
 
111966
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/call.mjs
112143
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/call.mjs
111967
112144
  var orgMiddleware, orgSessionMiddleware;
111968
112145
  var init_call = __esm({
111969
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/call.mjs"() {
112146
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/call.mjs"() {
111970
112147
  init_session2();
111971
112148
  init_api2();
111972
112149
  orgMiddleware = createAuthMiddleware(async () => {
@@ -111978,7 +112155,7 @@ var init_call = __esm({
111978
112155
  }
111979
112156
  });
111980
112157
 
111981
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/routes/crud-access-control.mjs
112158
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/routes/crud-access-control.mjs
111982
112159
  async function checkForInvalidResources({ ac, ctx, permission }) {
111983
112160
  const validResources = Object.keys(ac.statements);
111984
112161
  const providedResources = Object.keys(permission);
@@ -112068,7 +112245,7 @@ async function checkIfRoleNameIsTakenByRoleInDB({ organizationId, role: role2, c
112068
112245
  }
112069
112246
  var normalizeRoleName, DEFAULT_MAXIMUM_ROLES_PER_ORGANIZATION, getAdditionalFields, baseCreateOrgRoleSchema, createOrgRole, deleteOrgRoleBodySchema, deleteOrgRole, listOrgRolesQuerySchema, listOrgRoles, getOrgRoleQuerySchema, getOrgRole, roleNameOrIdSchema, updateOrgRole;
112070
112247
  var init_crud_access_control = __esm({
112071
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/routes/crud-access-control.mjs"() {
112248
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/routes/crud-access-control.mjs"() {
112072
112249
  init_to_zod();
112073
112250
  init_error_codes2();
112074
112251
  init_call();
@@ -112659,10 +112836,10 @@ Please refer to the documentation here: https://better-auth.com/docs/plugins/org
112659
112836
  }
112660
112837
  });
112661
112838
 
112662
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/routes/crud-invites.mjs
112839
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/routes/crud-invites.mjs
112663
112840
  var baseInvitationSchema, getAdvancedGenerateId, hasBuiltInOpaqueInvitationIdGeneration, shouldRequireVerifiedEmailForInvitationIdAction, createInvitation, acceptInvitationBodySchema, acceptInvitation, rejectInvitationBodySchema, rejectInvitation, cancelInvitationBodySchema, cancelInvitation, getInvitationQuerySchema, getInvitation, listInvitationQuerySchema, listInvitations, listUserInvitations;
112664
112841
  var init_crud_invites = __esm({
112665
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/routes/crud-invites.mjs"() {
112842
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/routes/crud-invites.mjs"() {
112666
112843
  init_date();
112667
112844
  init_cookies2();
112668
112845
  init_to_zod();
@@ -113262,10 +113439,10 @@ var init_crud_invites = __esm({
113262
113439
  }
113263
113440
  });
113264
113441
 
113265
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/routes/crud-members.mjs
113442
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/routes/crud-members.mjs
113266
113443
  var baseMemberSchema, addMember, removeMemberBodySchema, removeMember, updateMemberRoleBodySchema, updateMemberRole, getActiveMember, leaveOrganizationBodySchema, leaveOrganization, listMembers, getActiveMemberRoleQuerySchema, getActiveMemberRole;
113267
113444
  var init_crud_members = __esm({
113268
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/routes/crud-members.mjs"() {
113445
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/routes/crud-members.mjs"() {
113269
113446
  init_to_zod();
113270
113447
  init_session2();
113271
113448
  init_statement();
@@ -113784,10 +113961,10 @@ var init_crud_members = __esm({
113784
113961
  }
113785
113962
  });
113786
113963
 
113787
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/routes/crud-org.mjs
113964
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/routes/crud-org.mjs
113788
113965
  var baseOrganizationSchema, createOrganization, checkOrganizationSlugBodySchema, checkOrganizationSlug, baseUpdateOrganizationSchema, updateOrganization, deleteOrganizationBodySchema, deleteOrganization, getOrganizationQuerySchema, getOrganization, getFullOrganizationQuerySchema, getFullOrganization, setActiveOrganizationBodySchema, setActiveOrganization, listOrganizations;
113789
113966
  var init_crud_org = __esm({
113790
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/routes/crud-org.mjs"() {
113967
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/routes/crud-org.mjs"() {
113791
113968
  init_cookies2();
113792
113969
  init_to_zod();
113793
113970
  init_session2();
@@ -114240,10 +114417,10 @@ var init_crud_org = __esm({
114240
114417
  }
114241
114418
  });
114242
114419
 
114243
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/schema.mjs
114420
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/schema.mjs
114244
114421
  var roleSchema, invitationStatus, teamSchema, defaultRoles2;
114245
114422
  var init_schema3 = __esm({
114246
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/schema.mjs"() {
114423
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/schema.mjs"() {
114247
114424
  init_id2();
114248
114425
  init_zod();
114249
114426
  roleSchema = string2();
@@ -114309,10 +114486,10 @@ var init_schema3 = __esm({
114309
114486
  }
114310
114487
  });
114311
114488
 
114312
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/routes/crud-team.mjs
114489
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/routes/crud-team.mjs
114313
114490
  var teamBaseSchema, createTeam, removeTeamBodySchema, removeTeam, updateTeam, listOrganizationTeamsQuerySchema, listOrganizationTeams, setActiveTeamBodySchema, setActiveTeam, listUserTeams, listTeamMembersQuerySchema, listTeamMembers, addTeamMemberBodySchema, addTeamMember, removeTeamMemberBodySchema, removeTeamMember;
114314
114491
  var init_crud_team = __esm({
114315
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/routes/crud-team.mjs"() {
114492
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/routes/crud-team.mjs"() {
114316
114493
  init_cookies2();
114317
114494
  init_to_zod();
114318
114495
  init_session2();
@@ -115080,7 +115257,7 @@ var init_crud_team = __esm({
115080
115257
  }
115081
115258
  });
115082
115259
 
115083
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/organization.mjs
115260
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/organization.mjs
115084
115261
  function parseRoles(roles) {
115085
115262
  return Array.isArray(roles) ? roles.join(",") : roles;
115086
115263
  }
@@ -115891,7 +116068,7 @@ function organization(options) {
115891
116068
  }
115892
116069
  var createHasPermissionBodySchema, createHasPermission;
115893
116070
  var init_organization = __esm({
115894
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/organization.mjs"() {
116071
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/organization.mjs"() {
115895
116072
  init_session2();
115896
116073
  init_version4();
115897
116074
  init_statement();
@@ -115970,7 +116147,7 @@ var init_organization = __esm({
115970
116147
  }
115971
116148
  });
115972
116149
 
115973
- // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/index.mjs
116150
+ // ../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/index.mjs
115974
116151
  var organization_exports = {};
115975
116152
  __export(organization_exports, {
115976
116153
  getOrgAdapter: () => getOrgAdapter,
@@ -115979,14 +116156,14 @@ __export(organization_exports, {
115979
116156
  parseRoles: () => parseRoles
115980
116157
  });
115981
116158
  var init_organization2 = __esm({
115982
- "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_9e8f90c40614849e7a32e3ab5b745f3a/node_modules/better-auth/dist/plugins/organization/index.mjs"() {
116159
+ "../../node_modules/.pnpm/better-auth@1.7.6_@opentelemetry+api@1.9.1_@prisma+client@5.22.0_drizzle-kit@0.31.11_dr_22713e62280c548d1e4e1f724a123319/node_modules/better-auth/dist/plugins/organization/index.mjs"() {
115983
116160
  init_adapter2();
115984
116161
  init_has_permission();
115985
116162
  init_organization();
115986
116163
  }
115987
116164
  });
115988
116165
 
115989
- // ../../node_modules/.pnpm/@better-auth+api-key@1.7.6_@better-auth+core@1.7.6_@better-auth+utils@0.5.0_@better-fet_614509f08999547ecfbbff9e687b5da6/node_modules/@better-auth/api-key/dist/index.mjs
116166
+ // ../../node_modules/.pnpm/@better-auth+api-key@1.7.6_@better-auth+core@1.7.6_@better-auth+utils@0.5.0_@better-fet_9f33cd4e6a3de2100016969b8e81afec/node_modules/@better-auth/api-key/dist/index.mjs
115990
116167
  function parseDoubleStringifiedMetadata(metadata) {
115991
116168
  if (metadata == null) return null;
115992
116169
  if (typeof metadata === "object") return metadata;
@@ -118085,7 +118262,7 @@ function apiKey(_configurations, _options) {
118085
118262
  }
118086
118263
  var STORAGE_CONCURRENCY, refListLocks, getDate2, createApiKeyBodySchema, deleteApiKeyBodySchema, getApiKeyQuerySchema, listApiKeysQuerySchema, updateApiKeyBodySchema, verifyApiKeyBodySchema, lastChecked, apiKeySchema, defaultKeyHasher2, API_KEY_TABLE_NAME;
118087
118264
  var init_dist16 = __esm({
118088
- "../../node_modules/.pnpm/@better-auth+api-key@1.7.6_@better-auth+core@1.7.6_@better-auth+utils@0.5.0_@better-fet_614509f08999547ecfbbff9e687b5da6/node_modules/@better-auth/api-key/dist/index.mjs"() {
118265
+ "../../node_modules/.pnpm/@better-auth+api-key@1.7.6_@better-auth+core@1.7.6_@better-auth+utils@0.5.0_@better-fet_9f33cd4e6a3de2100016969b8e81afec/node_modules/@better-auth/api-key/dist/index.mjs"() {
118089
118266
  init_version_BjgKH8I0();
118090
118267
  init_api2();
118091
118268
  init_ip();
@@ -122434,9 +122611,9 @@ function construct(client2, config3 = {}) {
122434
122611
  };
122435
122612
  }
122436
122613
  const session2 = new BetterSQLiteSession(client2, dialect, schema3, { logger: logger3 });
122437
- const db = new BetterSQLite3Database("sync", dialect, session2, schema3);
122438
- db.$client = client2;
122439
- return db;
122614
+ const db2 = new BetterSQLite3Database("sync", dialect, session2, schema3);
122615
+ db2.$client = client2;
122616
+ return db2;
122440
122617
  }
122441
122618
  function drizzle(...params) {
122442
122619
  if (params[0] === void 0 || typeof params[0] === "string") {
@@ -122523,9 +122700,9 @@ var init_migrator2 = __esm({
122523
122700
  });
122524
122701
 
122525
122702
  // ../../node_modules/.pnpm/drizzle-orm@0.45.3_@electric-sql+pglite@0.5.8_@neondatabase+serverless@1.1.0_@opentelem_30a1d0dbd5a797b7a9423103d631b055/node_modules/drizzle-orm/better-sqlite3/migrator.js
122526
- function migrate(db, config3) {
122703
+ function migrate(db2, config3) {
122527
122704
  const migrations = readMigrationFiles(config3);
122528
- db.dialect.migrate(migrations, db.session, config3);
122705
+ db2.dialect.migrate(migrations, db2.session, config3);
122529
122706
  }
122530
122707
  var init_migrator3 = __esm({
122531
122708
  "../../node_modules/.pnpm/drizzle-orm@0.45.3_@electric-sql+pglite@0.5.8_@neondatabase+serverless@1.1.0_@opentelem_30a1d0dbd5a797b7a9423103d631b055/node_modules/drizzle-orm/better-sqlite3/migrator.js"() {
@@ -122859,6 +123036,13 @@ var init_approvals = __esm({
122859
123036
  * restart.
122860
123037
  */
122861
123038
  blockedRequest: integer2("blocked_request", { mode: "boolean" }).notNull().default(false),
123039
+ /**
123040
+ * Whether granting it could raise what agents may do: the call reaches the
123041
+ * Permissions, Safety limits or Reach & secrets areas (DOR-3037). Set when
123042
+ * the card is made, from the call's input, which the row does not keep. A
123043
+ * Wi-Fi sign-in may not grant such a card, even once.
123044
+ */
123045
+ raisesPermissions: integer2("raises_permissions", { mode: "boolean" }).notNull().default(false),
122862
123046
  /**
122863
123047
  * The reason the agent gave with a blocked request, capped and swept for
122864
123048
  * secrets like the summary. Null on every other approval.
@@ -123545,6 +123729,12 @@ var init_sessions = __esm({
123545
123729
  // here, not on the `session_limits` row, because the resumed turn's own
123546
123730
  // `turn_start` deletes that row. NULL = never resumed automatically.
123547
123731
  lastAutoResumeFor: text("last_auto_resume_for"),
123732
+ // Whether this chat's latest turn read words DorkOS cannot vouch for, such
123733
+ // as a Wi-Fi sign-in's, so it ran at the runtime's default at most
123734
+ // (DOR-3037). Every turn that picks the chat up on its own (an approval's
123735
+ // answer, a resume, a wake) is held the same way, after a restart too.
123736
+ // NULL = no turn recorded since this column existed: read as held.
123737
+ lastTurnHeld: integer2("last_turn_held", { mode: "boolean" }),
123548
123738
  createdAt: text("created_at").notNull(),
123549
123739
  // --- Mutable per-session settings (last-write-wins; ADR-0260) ---
123550
123740
  // NULL = "no explicit preference; use the runtime's default."
@@ -123575,7 +123765,12 @@ var init_sessions = __esm({
123575
123765
  clientId: text("client_id").notNull(),
123576
123766
  enqueuedAt: integer2("enqueued_at").notNull(),
123577
123767
  // The `ClientContext` captured at enqueue time, JSON. NULL = none was sent.
123578
- contextJson: text("context_json")
123768
+ contextJson: text("context_json"),
123769
+ // Whether the turn this row starts is held to the runtime's default level,
123770
+ // because the words came from somewhere DorkOS cannot vouch for (a Wi-Fi
123771
+ // sign-in, DOR-3037). Kept on the row so the hold survives a restart and an
123772
+ // edit, when no in-memory plan carries the turn's ceiling.
123773
+ heldToDefault: integer2("held_to_default", { mode: "boolean" }).notNull().default(false)
123579
123774
  },
123580
123775
  (t2) => ({
123581
123776
  // (session_id, position) rather than session_id alone: every read of this
@@ -125448,6 +125643,12 @@ var init_rooms2 = __esm({
125448
125643
  * restart does not read a teammate-marked agent post as merely an outsider's. Off the wire.
125449
125644
  */
125450
125645
  turnMarks: text("turn_marks"),
125646
+ /**
125647
+ * Whether the turns this post starts, and the beats that read it, are held
125648
+ * to the runtime's default: a person wrote it from Wi-Fi (DOR-3037). Kept on
125649
+ * the row so the hold outlives a restart. Off the wire, like `dispatchId`.
125650
+ */
125651
+ heldToDefault: integer2("held_to_default", { mode: "boolean" }).notNull().default(false),
125451
125652
  /** The entry this one answers, in this same room. Null for a top-level entry. */
125452
125653
  parentEntryId: text("parent_entry_id"),
125453
125654
  /**
@@ -127957,8 +128158,8 @@ function configureAndWrap(sqlite) {
127957
128158
  sqlite.pragma("secure_delete = ON");
127958
128159
  return drizzle(sqlite, { schema: schema_exports });
127959
128160
  }
127960
- function runMigrations(db) {
127961
- migrate(db, { migrationsFolder: migrationsFolder() });
128161
+ function runMigrations(db2) {
128162
+ migrate(db2, { migrationsFolder: migrationsFolder() });
127962
128163
  }
127963
128164
  var DatabaseOpenError;
127964
128165
  var init_src2 = __esm({
@@ -128886,8 +129087,8 @@ var init_trusted_origins2 = __esm({
128886
129087
  });
128887
129088
 
128888
129089
  // ../../apps/server/src/services/core/auth/accounts.ts
128889
- function findOwnerAccount(db) {
128890
- return db.select({ id: user.id, name: user.name }).from(user).orderBy(asc(user.createdAt)).limit(1).get() ?? null;
129090
+ function findOwnerAccount(db2) {
129091
+ return db2.select({ id: user.id, name: user.name }).from(user).orderBy(asc(user.createdAt)).limit(1).get() ?? null;
128891
129092
  }
128892
129093
  var init_accounts = __esm({
128893
129094
  "../../apps/server/src/services/core/auth/accounts.ts"() {
@@ -129116,10 +129317,11 @@ var init_cookie_security = __esm({
129116
129317
  });
129117
129318
 
129118
129319
  // ../shared/src/session-relay.ts
129119
- var SESSION_RELAY_MAX_FRAME_LENGTH, SESSION_RELAY_MAX_INNER_FRAME_BYTES, SESSION_RELAY_MAX_MESSAGE_LENGTH, RelayMessageContentSchema, SESSION_RELAY_MAX_CHATS, SESSION_RELAY_IDLE_CLOSE_MS, VersionSchema, RelayVersionRangeSchema, RelayAdvertisedFeaturesSchema, RelayRequestIdSchema, StreamIdSchema, RelaySessionIdSchema, RelayAgentIdSchema, ToolCallIdSchema, ResumeCursorSchema, NO_CONTROL, INVISIBLE, RelayDisplayNameSchema, RelayDeviceSchema, base64url3, ChatsListRequestSchema, SessionStreamRequestSchema, SessionSendRequestSchema, SessionInterruptRequestSchema, ApprovalDecisionSchema, InteractionChallengeRequestSchema, RelayApprovalProofSchema, InteractionAnswerSchema, InteractionRespondRequestSchema, RelayRequestSchema, RelayChatSummarySchema, RelayResultBodySchemas, RelayErrorSchema, exactBase64url, RelayEphemeralKeySchema, RelaySignatureSchema, RelayNonceSchema, RelayPinnedHubKeySchema, RelayHelloFrameSchema, RelayHandshakeAnswerSchema, RelaySealedFrameSchema, HeartbeatFrameSchema, RelayWebFrameSchema, RelayStreamFrameSchema, RelayComputerFrameSchema, RelayFinishFrameSchema;
129320
+ var SESSION_RELAY_MAX_FRAME_LENGTH, SESSION_RELAY_MAX_INNER_FRAME_BYTES, SESSION_RELAY_MAX_MESSAGE_LENGTH, RelayMessageContentSchema, SESSION_RELAY_MAX_CHATS, SESSION_RELAY_IDLE_CLOSE_MS, VersionSchema, RelayVersionRangeSchema, RelayAdvertisedFeaturesSchema, RelayRequestIdSchema, StreamIdSchema, RelaySessionIdSchema, RelayAgentIdSchema, ToolCallIdSchema2, ResumeCursorSchema, NO_CONTROL2, INVISIBLE2, RelayDisplayNameSchema, RelayDeviceSchema, base64url4, ChatsListRequestSchema, SessionStreamRequestSchema, SessionSendRequestSchema, SessionInterruptRequestSchema, ApprovalDecisionSchema, InteractionChallengeRequestSchema, RelayApprovalProofSchema, InteractionAnswerSchema, InteractionRespondRequestSchema, RelayRequestSchema, RelayChatSummarySchema, RelayResultBodySchemas, RelayErrorSchema, exactBase64url, RelayEphemeralKeySchema, RelaySignatureSchema, RelayNonceSchema, RelayPinnedHubKeySchema, RelayHelloFrameSchema, RelayHandshakeAnswerSchema, RelaySealedFrameSchema, HeartbeatFrameSchema, RelayWebFrameSchema, RelayStreamFrameSchema, RelayComputerFrameSchema, RelayFinishFrameSchema;
129120
129321
  var init_session_relay = __esm({
129121
129322
  "../shared/src/session-relay.ts"() {
129122
129323
  "use strict";
129324
+ init_dist15();
129123
129325
  init_zod();
129124
129326
  init_schemas4();
129125
129327
  SESSION_RELAY_MAX_FRAME_LENGTH = 1048576;
@@ -129135,16 +129337,16 @@ var init_session_relay = __esm({
129135
129337
  StreamIdSchema = RelayRequestIdSchema;
129136
129338
  RelaySessionIdSchema = external_exports.string().regex(/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/);
129137
129339
  RelayAgentIdSchema = external_exports.string().regex(/^[0-9A-HJKMNP-TV-Z]{26}$/);
129138
- ToolCallIdSchema = external_exports.string().min(1).max(256).regex(/^[\w.:-]+$/);
129340
+ ToolCallIdSchema2 = external_exports.string().min(1).max(256).regex(/^[\w.:-]+$/);
129139
129341
  ResumeCursorSchema = external_exports.string().max(256).regex(/^[0-9a-f-]+-\d+-g\d+-\d+$/);
129140
- NO_CONTROL = /^[^\u0000-\u001f\u007f]*$/;
129141
- INVISIBLE = /[\p{Cf}\u2028\u2029]/u;
129142
- RelayDisplayNameSchema = external_exports.string().min(1).max(64).regex(NO_CONTROL).refine((name2) => name2.trim() === name2, "no leading or trailing whitespace").refine((name2) => !INVISIBLE.test(name2), "no invisible characters");
129342
+ NO_CONTROL2 = /^[^\u0000-\u001f\u007f]*$/;
129343
+ INVISIBLE2 = /[\p{Cf}\u2028\u2029]/u;
129344
+ RelayDisplayNameSchema = external_exports.string().min(1).max(64).regex(NO_CONTROL2).refine((name2) => name2.trim() === name2, "no leading or trailing whitespace").refine((name2) => !INVISIBLE2.test(name2), "no invisible characters");
129143
129345
  RelayDeviceSchema = external_exports.strictObject({
129144
129346
  id: external_exports.string().min(8).max(64).regex(/^[A-Za-z0-9_-]+$/),
129145
129347
  label: RelayDisplayNameSchema
129146
129348
  });
129147
- base64url3 = (max2) => external_exports.string().min(1).max(max2).regex(/^[A-Za-z0-9_-]+$/);
129349
+ base64url4 = (max2) => external_exports.string().min(1).max(max2).regex(/^[A-Za-z0-9_-]+$/);
129148
129350
  ChatsListRequestSchema = external_exports.strictObject({
129149
129351
  op: external_exports.literal("chats.list"),
129150
129352
  agentId: RelayAgentIdSchema
@@ -129171,33 +129373,25 @@ var init_session_relay = __esm({
129171
129373
  InteractionChallengeRequestSchema = external_exports.strictObject({
129172
129374
  op: external_exports.literal("interaction.challenge"),
129173
129375
  sessionId: RelaySessionIdSchema,
129174
- toolCallId: ToolCallIdSchema,
129376
+ toolCallId: ToolCallIdSchema2,
129175
129377
  decision: ApprovalDecisionSchema
129176
129378
  });
129177
- RelayApprovalProofSchema = external_exports.strictObject({
129178
- /** The `challengeId` the computer answered `interaction.challenge` with. */
129179
- challengeId: RelayRequestIdSchema,
129180
- credentialId: base64url3(1400),
129181
- clientDataJSON: base64url3(4096),
129182
- authenticatorData: base64url3(1024),
129183
- signature: base64url3(512),
129184
- userHandle: base64url3(128).optional()
129185
- });
129379
+ RelayApprovalProofSchema = StepUpAssertionSchema;
129186
129380
  InteractionAnswerSchema = external_exports.discriminatedUnion("kind", [
129187
129381
  external_exports.strictObject({
129188
129382
  kind: external_exports.literal("approve"),
129189
- toolCallId: ToolCallIdSchema,
129383
+ toolCallId: ToolCallIdSchema2,
129190
129384
  proof: RelayApprovalProofSchema
129191
129385
  }),
129192
129386
  external_exports.strictObject({
129193
129387
  kind: external_exports.literal("deny"),
129194
- toolCallId: ToolCallIdSchema,
129388
+ toolCallId: ToolCallIdSchema2,
129195
129389
  reason: external_exports.string().max(DENY_REASON_MAX_LENGTH).optional(),
129196
129390
  proof: RelayApprovalProofSchema
129197
129391
  }),
129198
129392
  external_exports.strictObject({
129199
129393
  kind: external_exports.literal("answer"),
129200
- toolCallId: ToolCallIdSchema,
129394
+ toolCallId: ToolCallIdSchema2,
129201
129395
  answers: external_exports.record(external_exports.string().regex(/^\d{1,3}$/), external_exports.string().max(1e4))
129202
129396
  })
129203
129397
  ]);
@@ -129229,10 +129423,20 @@ var init_session_relay = __esm({
129229
129423
  receipt: InterruptReceiptSchema,
129230
129424
  cancelledQueued: external_exports.array(QueuedMessageSchema)
129231
129425
  }),
129426
+ /**
129427
+ * The statement to sign. There is no separate challenge: the passkey signs
129428
+ * `stepUpChallenge(bytes)` (`@dork-labs/cloud-api`) over the decoded
129429
+ * statement bytes, never a value the hub hands over. `challengeId` and
129430
+ * `expiresAt` repeat the statement's own, so a hub must check they match
129431
+ * before using them ({@link assertChallengeResultMatches}). Changed without a
129432
+ * version bump: no build has ever answered `interaction.challenge` (the
129433
+ * computer refuses it, `refuseApproval`), so no peer has ever parsed this
129434
+ * result.
129435
+ */
129232
129436
  "interaction.challenge": external_exports.strictObject({
129233
129437
  challengeId: RelayRequestIdSchema,
129234
- /** The bytes to sign, base64url. Opaque to the web side. */
129235
- challenge: base64url3(256),
129438
+ /** The `dorkos.relay.approval.v1` statement bytes, base64url. */
129439
+ statement: base64url4(STEP_UP_STATEMENT_MAX_BASE64URL_LENGTH),
129236
129440
  /** When the computer stops accepting a proof over it. */
129237
129441
  expiresAt: external_exports.string().datetime()
129238
129442
  }),
@@ -129340,7 +129544,7 @@ var init_session_relay = __esm({
129340
129544
  });
129341
129545
 
129342
129546
  // ../shared/src/session-relay-link.ts
129343
- var RELAY_LINK_CODE_TTL_MS, RelayLinkComputerIdSchema, Sha256Base64urlSchema, NO_CONTROL2, RelayLinkComputerNameSchema, RelayLinkRequestSchema, RelayLinkResponseSchema, HubComputerSummarySchema, HubComputerListSchema, HubLinkCodeSchema, SessionRelayLevelSchema, SessionRelayStatusSchema, StepUpPasswordSchema, SessionRelayLinkBodySchema, SessionRelayLevelBodySchema, SessionRelayResumeBodySchema, SessionRelayLinkRefusalSchema, SessionRelayDeviceSchema, SessionRelayPresenceSchema, SessionRelayDeviceListSchema;
129547
+ var RELAY_LINK_CODE_TTL_MS, RelayLinkComputerIdSchema, Sha256Base64urlSchema, NO_CONTROL3, RelayLinkComputerNameSchema, RelayLinkRequestSchema, RelayLinkResponseSchema, HubComputerSummarySchema, HubComputerListSchema, HubLinkCodeSchema, SessionRelayLevelSchema, SessionRelayStatusSchema, StepUpPasswordSchema, SessionRelayLinkBodySchema, SessionRelayLevelBodySchema, SessionRelayResumeBodySchema, SessionRelayLinkRefusalSchema, SessionRelayDeviceSchema, SessionRelayPresenceSchema, SessionRelayDeviceListSchema, SessionRelayPasskeyLabelSchema, SessionRelayPasskeyStartBodySchema, SessionRelayPasskeyStartSchema, base64urlText, SessionRelayPasskeyAttestationSchema, SessionRelayPasskeyFinishBodySchema, SessionRelayPasskeySchema, SessionRelayPasskeyListSchema, SessionRelayPasskeyRemoveBodySchema;
129344
129548
  var init_session_relay_link = __esm({
129345
129549
  "../shared/src/session-relay-link.ts"() {
129346
129550
  init_zod();
@@ -129348,7 +129552,7 @@ var init_session_relay_link = __esm({
129348
129552
  RELAY_LINK_CODE_TTL_MS = 10 * 60 * 1e3;
129349
129553
  RelayLinkComputerIdSchema = external_exports.string().min(1).max(64).regex(/^[\w.:-]+$/);
129350
129554
  Sha256Base64urlSchema = external_exports.string().length(43).regex(/^[A-Za-z0-9_-]+$/);
129351
- NO_CONTROL2 = /^[^\u0000-\u001f\u007f]*$/;
129555
+ NO_CONTROL3 = /^[^\u0000-\u001f\u007f]*$/;
129352
129556
  RelayLinkComputerNameSchema = RelayDisplayNameSchema;
129353
129557
  RelayLinkRequestSchema = external_exports.strictObject({
129354
129558
  v: external_exports.literal(1),
@@ -129367,9 +129571,9 @@ var init_session_relay_link = __esm({
129367
129571
  /** The hub's Ed25519 public key, raw 32 bytes base64url. Pin this one. */
129368
129572
  hubKey: RelayPinnedHubKeySchema,
129369
129573
  /** The hub owner's account id at `issuer`. */
129370
- ownerAccountId: external_exports.string().min(1).max(128).regex(NO_CONTROL2).optional(),
129574
+ ownerAccountId: external_exports.string().min(1).max(128).regex(NO_CONTROL3).optional(),
129371
129575
  /** The issuer that account id belongs to. */
129372
- issuer: external_exports.string().min(1).max(512).startsWith("https://").regex(NO_CONTROL2).optional(),
129576
+ issuer: external_exports.string().min(1).max(512).startsWith("https://").regex(NO_CONTROL3).optional(),
129373
129577
  signature: RelaySignatureSchema
129374
129578
  });
129375
129579
  HubComputerSummarySchema = external_exports.object({
@@ -129457,6 +129661,63 @@ var init_session_relay_link = __esm({
129457
129661
  SessionRelayDeviceListSchema = external_exports.object({
129458
129662
  devices: external_exports.array(SessionRelayDeviceSchema)
129459
129663
  });
129664
+ SessionRelayPasskeyLabelSchema = external_exports.string().trim().min(1).max(64).regex(/^[^\u0000-\u001f\u007f]*$/);
129665
+ SessionRelayPasskeyStartBodySchema = external_exports.object({
129666
+ /** The owner's password; see `StepUpPasswordSchema`. */
129667
+ password: StepUpPasswordSchema.optional(),
129668
+ label: SessionRelayPasskeyLabelSchema,
129669
+ /** The relying party: the approve page's host. Derived from `origin` when left out. */
129670
+ rpId: external_exports.string().min(1).max(253).optional(),
129671
+ /** The approve page's https origin. */
129672
+ origin: external_exports.string().min(1).max(256).optional()
129673
+ });
129674
+ SessionRelayPasskeyStartSchema = external_exports.object({
129675
+ /** The enrol statement, base64url of its canonical bytes. */
129676
+ statement: external_exports.string(),
129677
+ /** The WebAuthn challenge: base64url `SHA-256` of the statement bytes. */
129678
+ challenge: external_exports.string(),
129679
+ /** The approve page's enrol page, the statement in its fragment. Open it in a browser. */
129680
+ approveUrl: external_exports.string(),
129681
+ /** When the statement stops being accepted (ISO 8601). */
129682
+ expiresAt: external_exports.string()
129683
+ });
129684
+ base64urlText = (max2) => external_exports.string().min(1).max(max2).regex(/^[A-Za-z0-9_-]+$/);
129685
+ SessionRelayPasskeyAttestationSchema = external_exports.object({
129686
+ id: base64urlText(1400),
129687
+ rawId: base64urlText(1400),
129688
+ type: external_exports.literal("public-key"),
129689
+ response: external_exports.object({
129690
+ clientDataJSON: base64urlText(4096),
129691
+ attestationObject: base64urlText(16384),
129692
+ transports: external_exports.array(external_exports.string().max(32)).max(8).optional()
129693
+ }),
129694
+ clientExtensionResults: external_exports.record(external_exports.string(), external_exports.unknown()).default({}),
129695
+ authenticatorAttachment: external_exports.enum(["platform", "cross-platform"]).optional()
129696
+ });
129697
+ SessionRelayPasskeyFinishBodySchema = external_exports.object({
129698
+ statement: base64urlText(8192),
129699
+ attestation: SessionRelayPasskeyAttestationSchema
129700
+ });
129701
+ SessionRelayPasskeySchema = external_exports.object({
129702
+ credentialId: external_exports.string(),
129703
+ label: external_exports.string(),
129704
+ /** When it was added (ISO 8601). */
129705
+ addedAt: external_exports.string(),
129706
+ /** The COSE algorithm it signs with. */
129707
+ alg: external_exports.number().int()
129708
+ });
129709
+ SessionRelayPasskeyListSchema = external_exports.object({
129710
+ /** Present when the keys file is damaged: remove it (`DELETE /passkeys`) to start again. */
129711
+ damaged: external_exports.boolean().optional(),
129712
+ /** The pinned relying party; `null` until a passkey is added. */
129713
+ rpId: external_exports.string().nullable(),
129714
+ /** The pinned approve page; `null` until a passkey is added. */
129715
+ origin: external_exports.string().nullable(),
129716
+ keys: external_exports.array(SessionRelayPasskeySchema)
129717
+ });
129718
+ SessionRelayPasskeyRemoveBodySchema = external_exports.object({
129719
+ password: StepUpPasswordSchema.optional()
129720
+ });
129460
129721
  }
129461
129722
  });
129462
129723
 
@@ -129564,7 +129825,6 @@ function defuseSystemTags(text3, tagNames) {
129564
129825
  var IDENTITY_MAX_LENGTH, INVISIBLE_FORMAT, CONTROL_CHARS, PATTERN_CACHE;
129565
129826
  var init_untrusted_text = __esm({
129566
129827
  "../shared/src/untrusted-text.ts"() {
129567
- "use strict";
129568
129828
  IDENTITY_MAX_LENGTH = 80;
129569
129829
  INVISIBLE_FORMAT = /[\u00ad\u200b-\u200f\u202a-\u202e\u2060-\u2064\ufeff\ufff9-\ufffb]/g;
129570
129830
  CONTROL_CHARS = /[\u0000-\u001f\u007f-\u009f]/g;
@@ -129958,6 +130218,10 @@ var init_config_disclosure = __esm({
129958
130218
  // nothing an agent needs. A launch it asks for that the rules refuse is
129959
130219
  // answered with a sentence naming the project, which is all it can act on.
129960
130220
  "runtimes.claudeCode.accounts[].onlyProjects": "withhold",
130221
+ // Whether a person kept an account out of automatic moves (Re-seat P0). A
130222
+ // boolean preference that names no folder and no secret; an agent knowing
130223
+ // its seat will not move there on its own is harmless.
130224
+ "runtimes.claudeCode.accounts[].noAutoMove": "expose",
129961
130225
  "runtimes.claudeCode.defaultAccountOnlyProjects": "withhold",
129962
130226
  "runtimes.claudeCode.projectAccounts": "withhold",
129963
130227
  // The execution defaults a new session on each runtime starts with. A model id
@@ -130703,6 +130967,10 @@ var init_config_write_policy = __esm({
130703
130967
  // account the person kept out of that project. Written by a person through
130704
130968
  // the two `PUT /api/runtimes/claude-code/...` routes behind the person bar.
130705
130969
  "runtimes.claudeCode.accounts[].onlyProjects": "operator-only",
130970
+ // An account a person kept out of automatic moves (Re-seat P0). Clearing it
130971
+ // would let an agent's seat move onto an account the person reserved, which
130972
+ // is moving spend, so only a person changes it.
130973
+ "runtimes.claudeCode.accounts[].noAutoMove": "operator-only",
130706
130974
  "runtimes.claudeCode.defaultAccountOnlyProjects": "operator-only",
130707
130975
  "runtimes.claudeCode.projectAccounts": "operator-only",
130708
130976
  // The execution defaults for new sessions on each runtime. Writable, and the
@@ -130914,6 +131182,10 @@ var init_config_write_policy = __esm({
130914
131182
  "runtimes.claudeCode.defaultAccountColor",
130915
131183
  "runtimes.claudeCode.dismissedFolders",
130916
131184
  "runtimes.claudeCode.accounts[].onlyProjects",
131185
+ // Whether a room agent whose account ran out may be moved to this one on
131186
+ // its own (re-seat). Which account the work runs on: an agent clearing it
131187
+ // would move itself onto an account a person kept it off.
131188
+ "runtimes.claudeCode.accounts[].noAutoMove",
130917
131189
  "runtimes.claudeCode.defaultAccountOnlyProjects",
130918
131190
  "runtimes.claudeCode.projectAccounts"
130919
131191
  ]
@@ -135063,6 +135335,40 @@ var init_turn_marks = __esm({
135063
135335
  }
135064
135336
  });
135065
135337
 
135338
+ // ../../apps/server/src/services/core/turn-power/continuation-hold.ts
135339
+ function noteTurnHold(sessionId, held2) {
135340
+ if (!db) return;
135341
+ const key = primaryOf(sessionId);
135342
+ if (written.get(key) === held2) return;
135343
+ try {
135344
+ db.insert(sessionMetadata).values({
135345
+ sessionId: key,
135346
+ runtime: null,
135347
+ createdAt: (/* @__PURE__ */ new Date()).toISOString(),
135348
+ lastTurnHeld: held2
135349
+ }).onConflictDoUpdate({ target: sessionMetadata.sessionId, set: { lastTurnHeld: held2 } }).run();
135350
+ written.delete(key);
135351
+ written.set(key, held2);
135352
+ if (written.size > WRITTEN_MAX) written.delete(written.keys().next().value);
135353
+ } catch (err) {
135354
+ logger.warn("[continuation-hold] could not record the turn hold", {
135355
+ sessionId: key,
135356
+ err: err instanceof Error ? err.message : String(err)
135357
+ });
135358
+ }
135359
+ }
135360
+ var db, written, WRITTEN_MAX;
135361
+ var init_continuation_hold = __esm({
135362
+ "../../apps/server/src/services/core/turn-power/continuation-hold.ts"() {
135363
+ "use strict";
135364
+ init_src2();
135365
+ init_session_key_registry();
135366
+ init_logger();
135367
+ written = /* @__PURE__ */ new Map();
135368
+ WRITTEN_MAX = 1e4;
135369
+ }
135370
+ });
135371
+
135066
135372
  // ../../apps/server/src/services/core/turn-power/turn-levels.ts
135067
135373
  function remember(map4, key, level) {
135068
135374
  map4.delete(key);
@@ -135119,7 +135425,9 @@ function recordLevels(runtime, storedModeOf) {
135119
135425
  } catch {
135120
135426
  stored = void 0;
135121
135427
  }
135122
- remember(turnLevels, sessionId, levelForTurn(target, stored, opts));
135428
+ const level = levelForTurn(target, stored, opts);
135429
+ remember(turnLevels, sessionId, level);
135430
+ noteTurnHold(sessionId, level.outsider === true);
135123
135431
  const serial = ++nextTurnSerial;
135124
135432
  for (const id of /* @__PURE__ */ new Set([sessionId, primaryOf(sessionId)])) {
135125
135433
  turnSerials.delete(id);
@@ -135143,6 +135451,7 @@ var init_turn_levels = __esm({
135143
135451
  init_turn_marks();
135144
135452
  init_session_key_registry();
135145
135453
  init_outsider_turns();
135454
+ init_continuation_hold();
135146
135455
  init_permission_semantics();
135147
135456
  TURN_LEVEL_MEMORY = 1e4;
135148
135457
  AUTO_MODE_ID2 = "auto";
@@ -137163,8 +137472,8 @@ function renderEnvironment(report2) {
137163
137472
  return redactSecrets(lines.join("\n"));
137164
137473
  }
137165
137474
  function renderWritten(report2) {
137166
- const written = report2.body?.trim();
137167
- if (written) return [sanitizeWritten(written)];
137475
+ const written2 = report2.body?.trim();
137476
+ if (written2) return [sanitizeWritten(written2)];
137168
137477
  return report2.kind === "feature" ? ["## What do you want DorkOS to do?", "", "", "## Why would it help?", "", ""] : [
137169
137478
  "## What happened?",
137170
137479
  "",
@@ -137195,9 +137504,9 @@ function renderBody(report2) {
137195
137504
  ].join("\n");
137196
137505
  }
137197
137506
  function renderUrl(report2) {
137198
- const written = report2.title?.trim();
137507
+ const written2 = report2.title?.trim();
137199
137508
  const params = new URLSearchParams({
137200
- title: sanitizeWritten(written || TITLE_BY_KIND[report2.kind]),
137509
+ title: sanitizeWritten(written2 || TITLE_BY_KIND[report2.kind]),
137201
137510
  body: renderBody(report2),
137202
137511
  labels: LABELS_BY_KIND[report2.kind].join(",")
137203
137512
  });
@@ -137212,22 +137521,22 @@ function codePointPrefix(text3, count2) {
137212
137521
  function buildIssueDraft(report2, maxBytes = FEEDBACK_URL_MAX_BYTES) {
137213
137522
  const url2 = renderUrl(report2);
137214
137523
  if (byteLength(url2) <= maxBytes) return { url: url2, truncated: false };
137215
- const written = report2.body?.trim() ?? "";
137216
- if (!written) return { url: url2, truncated: false };
137217
- const points = Array.from(written).length;
137524
+ const written2 = report2.body?.trim() ?? "";
137525
+ if (!written2) return { url: url2, truncated: false };
137526
+ const points = Array.from(written2).length;
137218
137527
  let low = 0;
137219
137528
  let high = points;
137220
137529
  while (low < high) {
137221
137530
  const mid = Math.ceil((low + high) / 2);
137222
- const candidate = { ...report2, body: codePointPrefix(written, mid) + TRUNCATION_MARKER };
137531
+ const candidate = { ...report2, body: codePointPrefix(written2, mid) + TRUNCATION_MARKER };
137223
137532
  if (byteLength(renderUrl(candidate)) <= maxBytes) low = mid;
137224
137533
  else high = mid - 1;
137225
137534
  }
137226
- const shortened = { ...report2, body: codePointPrefix(written, low) + TRUNCATION_MARKER };
137535
+ const shortened = { ...report2, body: codePointPrefix(written2, low) + TRUNCATION_MARKER };
137227
137536
  return {
137228
137537
  url: renderUrl(shortened),
137229
137538
  truncated: true,
137230
- fullBody: sanitizeWritten(written)
137539
+ fullBody: sanitizeWritten(written2)
137231
137540
  };
137232
137541
  }
137233
137542
  function buildIssueUrl(report2) {
@@ -137924,11 +138233,11 @@ function fillNullsWith(seed) {
137924
138233
  }
137925
138234
  return update;
137926
138235
  }
137927
- function moveSessionContext(db, fromId, toId) {
137928
- const source = db.select().from(sessionContext).where(eq(sessionContext.sessionId, fromId)).get();
138236
+ function moveSessionContext(db2, fromId, toId) {
138237
+ const source = db2.select().from(sessionContext).where(eq(sessionContext.sessionId, fromId)).get();
137929
138238
  if (!source) return;
137930
- const destination = db.select().from(sessionContext).where(eq(sessionContext.sessionId, toId)).get();
137931
- db.transaction((tx) => {
138239
+ const destination = db2.select().from(sessionContext).where(eq(sessionContext.sessionId, toId)).get();
138240
+ db2.transaction((tx) => {
137932
138241
  tx.delete(sessionContext).where(eq(sessionContext.sessionId, fromId)).run();
137933
138242
  if (destination && destination.observedAt >= source.observedAt) return;
137934
138243
  tx.insert(sessionContext).values({ ...source, sessionId: toId }).onConflictDoUpdate({
@@ -137995,8 +138304,8 @@ var init_runtime_registry = __esm({
137995
138304
  * this once after `createDb()` — before any route or service uses a
137996
138305
  * session-scoped method. Session-scoped methods throw if called before this.
137997
138306
  */
137998
- setDb(db) {
137999
- this.db = db;
138307
+ setDb(db2) {
138308
+ this.db = db2;
138000
138309
  }
138001
138310
  /**
138002
138311
  * Get a runtime by type.
@@ -138076,11 +138385,11 @@ var init_runtime_registry = __esm({
138076
138385
  * settings change belongs to a session nobody has started yet.
138077
138386
  */
138078
138387
  async persistSessionRuntime(sessionId, runtime, origin, agentPath) {
138079
- const db = this.requireDb("persistSessionRuntime");
138388
+ const db2 = this.requireDb("persistSessionRuntime");
138080
138389
  const agent = await readAgentExecutionDefaults(agentPath);
138081
138390
  const seedPolicy = seedForTurn(sessionId, origin);
138082
138391
  const seed = this.seedForNewRow(runtime, { agent, seedPolicy });
138083
- const result2 = await db.insert(sessionMetadata).values({
138392
+ const result2 = await db2.insert(sessionMetadata).values({
138084
138393
  sessionId,
138085
138394
  runtime,
138086
138395
  agentPath: agentPath ?? null,
@@ -138132,8 +138441,8 @@ var init_runtime_registry = __esm({
138132
138441
  * @param sessionId - The minted session id whose launch never produced a turn
138133
138442
  */
138134
138443
  async forgetUnstartedSession(sessionId) {
138135
- const db = this.requireDb("forgetUnstartedSession");
138136
- db.delete(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).run();
138444
+ const db2 = this.requireDb("forgetUnstartedSession");
138445
+ db2.delete(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).run();
138137
138446
  return Promise.resolve();
138138
138447
  }
138139
138448
  /**
@@ -138181,8 +138490,8 @@ var init_runtime_registry = __esm({
138181
138490
  * @param sessionId - Session identifier
138182
138491
  */
138183
138492
  async resolveSessionRuntime(sessionId, options = {}) {
138184
- const db = this.requireDb("resolveSessionRuntime");
138185
- const row2 = db.select({ runtime: sessionMetadata.runtime }).from(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).get();
138493
+ const db2 = this.requireDb("resolveSessionRuntime");
138494
+ const row2 = db2.select({ runtime: sessionMetadata.runtime }).from(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).get();
138186
138495
  if (row2?.runtime) {
138187
138496
  const source = this.getNativeSessionAccount(sessionId);
138188
138497
  if (row2.runtime === "codex" && source && source !== resolveCodexHome())
@@ -138254,8 +138563,8 @@ var init_runtime_registry = __esm({
138254
138563
  if (caller.kind !== "operator" && caller.kind !== "program") return;
138255
138564
  if (!session2.cwd) return;
138256
138565
  await validateBoundaryOrDorkHome(session2.cwd);
138257
- const db = this.requireDb("rememberNativeSession");
138258
- db.transaction((tx) => {
138566
+ const db2 = this.requireDb("rememberNativeSession");
138567
+ db2.transaction((tx) => {
138259
138568
  const existing = tx.select().from(sessionMetadata).where(eq(sessionMetadata.sessionId, session2.id)).get();
138260
138569
  if (existing?.runtime && existing.runtime !== session2.runtime)
138261
138570
  throw new AmbiguousSessionError();
@@ -138287,9 +138596,9 @@ var init_runtime_registry = __esm({
138287
138596
  }
138288
138597
  /** Actual native directory, distinct from the agent's ownership provenance. */
138289
138598
  getNativeSessionCwd(sessionId) {
138290
- const db = this.db;
138291
- if (!db) return null;
138292
- return db.select({ cwd: sessionNativeBindings.cwd }).from(sessionNativeBindings).where(eq(sessionNativeBindings.sessionId, sessionId)).get()?.cwd ?? null;
138599
+ const db2 = this.db;
138600
+ if (!db2) return null;
138601
+ return db2.select({ cwd: sessionNativeBindings.cwd }).from(sessionNativeBindings).where(eq(sessionNativeBindings.sessionId, sessionId)).get()?.cwd ?? null;
138293
138602
  }
138294
138603
  // ---------------------------------------------------------------------------
138295
138604
  // Per-session settings store (SessionSettingsPort; ADR-0260)
@@ -138316,9 +138625,9 @@ var init_runtime_registry = __esm({
138316
138625
  * @param agentPath - The agent's directory, exactly as it was bound.
138317
138626
  */
138318
138627
  listSessionIdsForAgentPath(agentPath) {
138319
- const db = this.db;
138320
- if (!db) return /* @__PURE__ */ new Set();
138321
- const rows = db.select({ sessionId: sessionMetadata.sessionId }).from(sessionMetadata).where(eq(sessionMetadata.agentPath, agentPath)).all();
138628
+ const db2 = this.db;
138629
+ if (!db2) return /* @__PURE__ */ new Set();
138630
+ const rows = db2.select({ sessionId: sessionMetadata.sessionId }).from(sessionMetadata).where(eq(sessionMetadata.agentPath, agentPath)).all();
138322
138631
  return new Set(rows.map((row2) => row2.sessionId));
138323
138632
  }
138324
138633
  /**
@@ -138332,8 +138641,8 @@ var init_runtime_registry = __esm({
138332
138641
  * @param sessionId - Session identifier
138333
138642
  */
138334
138643
  async getSessionAgentPath(sessionId) {
138335
- const db = this.requireDb("getSessionAgentPath");
138336
- const row2 = db.select({ agentPath: sessionMetadata.agentPath }).from(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).get();
138644
+ const db2 = this.requireDb("getSessionAgentPath");
138645
+ const row2 = db2.select({ agentPath: sessionMetadata.agentPath }).from(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).get();
138337
138646
  return row2?.agentPath ?? null;
138338
138647
  }
138339
138648
  /**
@@ -138345,8 +138654,8 @@ var init_runtime_registry = __esm({
138345
138654
  * @param sessionId - Session identifier
138346
138655
  */
138347
138656
  getSessionLaunchOrigin(sessionId) {
138348
- const db = this.requireDb("getSessionLaunchOrigin");
138349
- const row2 = db.select({ launchOrigin: sessionMetadata.launchOrigin }).from(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).get();
138657
+ const db2 = this.requireDb("getSessionLaunchOrigin");
138658
+ const row2 = db2.select({ launchOrigin: sessionMetadata.launchOrigin }).from(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).get();
138350
138659
  return row2?.launchOrigin ?? null;
138351
138660
  }
138352
138661
  /**
@@ -138359,8 +138668,8 @@ var init_runtime_registry = __esm({
138359
138668
  * @param sessionId - Session identifier
138360
138669
  */
138361
138670
  getLastAutoResumeFor(sessionId) {
138362
- const db = this.requireDb("getLastAutoResumeFor");
138363
- const row2 = db.select({ lastAutoResumeFor: sessionMetadata.lastAutoResumeFor }).from(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).get();
138671
+ const db2 = this.requireDb("getLastAutoResumeFor");
138672
+ const row2 = db2.select({ lastAutoResumeFor: sessionMetadata.lastAutoResumeFor }).from(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).get();
138364
138673
  return row2?.lastAutoResumeFor ?? null;
138365
138674
  }
138366
138675
  /**
@@ -138374,8 +138683,8 @@ var init_runtime_registry = __esm({
138374
138683
  * `null` to put back "never" when the resume could not be sent
138375
138684
  */
138376
138685
  markAutoResumed(sessionId, episode) {
138377
- const db = this.requireDb("markAutoResumed");
138378
- db.insert(sessionMetadata).values({
138686
+ const db2 = this.requireDb("markAutoResumed");
138687
+ db2.insert(sessionMetadata).values({
138379
138688
  sessionId,
138380
138689
  runtime: null,
138381
138690
  createdAt: (/* @__PURE__ */ new Date()).toISOString(),
@@ -138393,8 +138702,8 @@ var init_runtime_registry = __esm({
138393
138702
  * @param sessionId - Session identifier
138394
138703
  */
138395
138704
  storedPermissionModeOf(sessionId) {
138396
- const db = this.requireDb("storedPermissionModeOf");
138397
- const row2 = db.select({ permissionMode: sessionMetadata.permissionMode }).from(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).get();
138705
+ const db2 = this.requireDb("storedPermissionModeOf");
138706
+ const row2 = db2.select({ permissionMode: sessionMetadata.permissionMode }).from(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).get();
138398
138707
  return row2?.permissionMode ?? null;
138399
138708
  }
138400
138709
  /**
@@ -138404,8 +138713,8 @@ var init_runtime_registry = __esm({
138404
138713
  * @param sessionId - Session identifier
138405
138714
  */
138406
138715
  async getSessionSettings(sessionId) {
138407
- const db = this.requireDb("getSessionSettings");
138408
- const row2 = db.select({
138716
+ const db2 = this.requireDb("getSessionSettings");
138717
+ const row2 = db2.select({
138409
138718
  permissionMode: sessionMetadata.permissionMode,
138410
138719
  model: sessionMetadata.model,
138411
138720
  effort: sessionMetadata.effort,
@@ -138439,10 +138748,10 @@ var init_runtime_registry = __esm({
138439
138748
  * @param settings - Partial settings to persist (omitted keys are untouched)
138440
138749
  */
138441
138750
  async saveSessionSettings(sessionId, settings) {
138442
- const db = this.requireDb("saveSessionSettings");
138751
+ const db2 = this.requireDb("saveSessionSettings");
138443
138752
  const patch = pickSettings(settings);
138444
138753
  if (Object.keys(patch).length === 0) return;
138445
- db.insert(sessionMetadata).values({
138754
+ db2.insert(sessionMetadata).values({
138446
138755
  sessionId,
138447
138756
  // No owner: a preference chosen in a picker is not a binding.
138448
138757
  runtime: null,
@@ -138462,8 +138771,8 @@ var init_runtime_registry = __esm({
138462
138771
  * @param sessionId - The id the caller minted.
138463
138772
  */
138464
138773
  async discardSessionSettings(sessionId) {
138465
- const db = this.requireDb("discardSessionSettings");
138466
- db.delete(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).run();
138774
+ const db2 = this.requireDb("discardSessionSettings");
138775
+ db2.delete(sessionMetadata).where(eq(sessionMetadata.sessionId, sessionId)).run();
138467
138776
  }
138468
138777
  /**
138469
138778
  * The `permission_mode` a CLAIM should write: the stored one if the runtime
@@ -138636,10 +138945,10 @@ var init_runtime_registry = __esm({
138636
138945
  */
138637
138946
  async rekeySessionSettings(fromId, toId) {
138638
138947
  if (fromId === toId) return;
138639
- const db = this.requireDb("rekeySessionSettings");
138948
+ const db2 = this.requireDb("rekeySessionSettings");
138640
138949
  withSessionLimitStore("rekey", (store) => store.rekeySession(fromId, toId));
138641
138950
  try {
138642
- moveSessionContext(db, fromId, toId);
138951
+ moveSessionContext(db2, fromId, toId);
138643
138952
  } catch (err) {
138644
138953
  logger.warn("[RuntimeRegistry] could not move a session context reading", {
138645
138954
  fromId,
@@ -138665,10 +138974,10 @@ var init_runtime_registry = __esm({
138665
138974
  err: err instanceof Error ? err.message : String(err)
138666
138975
  });
138667
138976
  }
138668
- const source = db.select().from(sessionMetadata).where(eq(sessionMetadata.sessionId, fromId)).get();
138977
+ const source = db2.select().from(sessionMetadata).where(eq(sessionMetadata.sessionId, fromId)).get();
138669
138978
  if (!source) return;
138670
- const destination = db.select().from(sessionMetadata).where(eq(sessionMetadata.sessionId, toId)).get();
138671
- db.transaction((tx) => {
138979
+ const destination = db2.select().from(sessionMetadata).where(eq(sessionMetadata.sessionId, toId)).get();
138980
+ db2.transaction((tx) => {
138672
138981
  const nativeSource = tx.select().from(sessionNativeBindings).where(eq(sessionNativeBindings.sessionId, fromId)).get();
138673
138982
  if (nativeSource) {
138674
138983
  tx.insert(sessionNativeBindings).values({ ...nativeSource, sessionId: toId }).onConflictDoNothing({ target: sessionNativeBindings.sessionId }).run();
@@ -138719,9 +139028,9 @@ var init_runtime_registry = __esm({
138719
139028
  getSessionBindings(ids) {
138720
139029
  const result2 = /* @__PURE__ */ new Map();
138721
139030
  if (ids.length === 0) return result2;
138722
- const db = this.requireDb("getSessionBindings");
139031
+ const db2 = this.requireDb("getSessionBindings");
138723
139032
  for (let i2 = 0; i2 < ids.length; i2 += BOUND_RUNTIME_CHUNK_SIZE) {
138724
- const rows = db.select({
139033
+ const rows = db2.select({
138725
139034
  sessionId: sessionMetadata.sessionId,
138726
139035
  runtime: sessionMetadata.runtime,
138727
139036
  createdAt: sessionMetadata.createdAt
@@ -138747,8 +139056,8 @@ var init_runtime_registry = __esm({
138747
139056
  getSessionSettingsMany(ids) {
138748
139057
  const result2 = /* @__PURE__ */ new Map();
138749
139058
  if (ids.length === 0) return result2;
138750
- const db = this.requireDb("getSessionSettingsMany");
138751
- const rows = db.select({
139059
+ const db2 = this.requireDb("getSessionSettingsMany");
139060
+ const rows = db2.select({
138752
139061
  sessionId: sessionMetadata.sessionId,
138753
139062
  permissionMode: sessionMetadata.permissionMode,
138754
139063
  model: sessionMetadata.model,
@@ -147623,7 +147932,7 @@ ${TOOL_NAME_NOTE}
147623
147932
  You are running inside DorkOS, a workspace for people and agents, as a co-worker
147624
147933
  on the team. You can do what a person can do in the app: make agents, schedule work,
147625
147934
  install packages, read activity, change settings. Siblings: managing-agents, scheduling-tasks,
147626
- using-the-marketplace, reading-activity, answering-dorkos-questions, working-in-room-repos, working-with-spin-off-chats, working-on-a-heartbeat.
147935
+ using-the-marketplace, reading-activity, answering-dorkos-questions, working-in-room-repos, working-with-spin-off-chats, working-on-a-heartbeat, continuing-on-another-account.
147627
147936
 
147628
147937
  ## Two ways to act, pick one
147629
147938
 
@@ -147770,6 +148079,69 @@ one section, where a patch of \`ui.sidebar.groups\` rewrites every section at on
147770
148079
  }
147771
148080
  });
147772
148081
 
148082
+ // ../operating-skills/src/skills/continuing-on-another-account.ts
148083
+ var continuingOnAnotherAccount;
148084
+ var init_continuing_on_another_account = __esm({
148085
+ "../operating-skills/src/skills/continuing-on-another-account.ts"() {
148086
+ "use strict";
148087
+ init_tool_name_note();
148088
+ continuingOnAnotherAccount = {
148089
+ name: "continuing-on-another-account",
148090
+ description: "Use when your room or DM seat was moved to another Claude account: a room line says you ran out of usage and are continuing on another account, switched accounts, or started a fresh chat because your earlier one expired, or your background opens with a summary of a previous session. Covers what moved and what did not, finishing an answer without repeating it, and who can move you.",
148091
+ body: `# Continuing on another account
148092
+
148093
+ ${TOOL_NAME_NOTE}
148094
+
148095
+ Each agent in a room or DM has one **seat** there: the chat it answers in. When the
148096
+ Claude account that chat runs on runs out of usage, DorkOS moves the seat to the
148097
+ account with the most usage left, and you carry on. Nobody had to step in.
148098
+
148099
+ ## How you can tell
148100
+
148101
+ - A quiet line in the room, about you: "\u2026 ran out of usage on Claude4, so it's
148102
+ continuing on Claude3.", "\u2026 is continuing on Claude3, because Claude4 is almost
148103
+ out of usage.", or, in a room with people from outside, "\u2026 switched accounts to
148104
+ keep answering."
148105
+ - "\u2026 started a fresh chat here. Its earlier one had expired." means Claude Code
148106
+ removed your old transcript. Same seat, nothing to recover.
148107
+ - Your background opens with a summary of the previous session: where it stopped,
148108
+ the files it touched, its last messages, and the path to its transcript.
148109
+
148110
+ ## What moved, and what did not
148111
+
148112
+ - **New:** this session, and the account it bills. Your memory of the old session
148113
+ is the summary, plus the room history in your context.
148114
+ - **The same:** your power. The new session copies the old one's permission mode,
148115
+ model and effort, never more. Any mark the old session carried (words from
148116
+ outside your owner's circle) carries too, so what you pass on is capped exactly as
148117
+ before.
148118
+ - **Unchanged:** your "Runs on" setting. Only this seat moved.
148119
+
148120
+ ## Finish, don't repeat
148121
+
148122
+ The turn you wake up in is usually the message the old session was answering.
148123
+
148124
+ 1. Read the summary and the room history first.
148125
+ 2. If the old session **already posted** an answer, do not answer again. Finish
148126
+ only what is left, if anything. Saying nothing more is fine.
148127
+ 3. If it was partway through work (files edited, a command run), check where that
148128
+ work stands and finish it rather than starting over.
148129
+ 4. Do not apologise for the move or explain it. The room already has its line.
148130
+
148131
+ ## Who can move you
148132
+
148133
+ DorkOS moves you on its own when your account runs out or is almost out, at most
148134
+ once per message. A person can also move you from your menu in the room
148135
+ ("Continue on another account\u2026"). You cannot move yourself: the move tool is
148136
+ for people only for now. If you think you need another account, say so to the
148137
+ person in the room and they can move you.
148138
+
148139
+ DorkOS credits are never picked for you. Only a person chooses those, in a chat.
148140
+ `
148141
+ };
148142
+ }
148143
+ });
148144
+
147773
148145
  // ../operating-skills/src/skills/managing-agents.ts
147774
148146
  var managingAgents;
147775
148147
  var init_managing_agents = __esm({
@@ -148358,7 +148730,7 @@ is running. The documentation exists for exactly this.
148358
148730
  Three places, and only the last one costs a request.
148359
148731
 
148360
148732
  **Your sibling skills.** operating-dorkos, managing-agents, scheduling-tasks,
148361
- using-the-marketplace, reading-activity, working-in-room-repos, using-the-agent-browser, working-with-spin-off-chats and working-on-a-heartbeat are seeded beside this one and give
148733
+ using-the-marketplace, reading-activity, working-in-room-repos, using-the-agent-browser, working-with-spin-off-chats, working-on-a-heartbeat and continuing-on-another-account are seeded beside this one and give
148362
148734
  exact tool names, tiers and gates. When one of them covers the question, answer
148363
148735
  from it: more precise than the docs, and free.
148364
148736
 
@@ -148971,6 +149343,7 @@ var init_pack = __esm({
148971
149343
  "../operating-skills/src/pack.ts"() {
148972
149344
  "use strict";
148973
149345
  init_operating_dorkos();
149346
+ init_continuing_on_another_account();
148974
149347
  init_managing_agents();
148975
149348
  init_scheduling_tasks();
148976
149349
  init_using_the_marketplace();
@@ -148990,7 +149363,8 @@ var init_pack = __esm({
148990
149363
  workingInRoomRepos,
148991
149364
  usingTheAgentBrowser,
148992
149365
  workingWithSpinOffChats,
148993
- workingOnAHeartbeat
149366
+ workingOnAHeartbeat,
149367
+ continuingOnAnotherAccount
148994
149368
  ];
148995
149369
  }
148996
149370
  });
@@ -150734,13 +151108,13 @@ function somethingIsAt(abs) {
150734
151108
  }
150735
151109
  }
150736
151110
  function applyDeclaration(repoRoot, declaration) {
150737
- const written = declareClaudeOnlySkill(repoRoot, declaration);
150738
- if (written.outcome !== "unwritable") return void 0;
151111
+ const written2 = declareClaudeOnlySkill(repoRoot, declaration);
151112
+ if (written2.outcome !== "unwritable") return void 0;
150739
151113
  return {
150740
151114
  name: declaration.name,
150741
151115
  source: declaration.path,
150742
151116
  rule: "manifest-unwritable",
150743
- reason: `DorkOS did not change ${written.path}: ${written.reason}. Add "${declaration.name}" to its "claudeOnlySkills" list yourself.`
151117
+ reason: `DorkOS did not change ${written2.path}: ${written2.reason}. Add "${declaration.name}" to its "claudeOnlySkills" list yourself.`
150744
151118
  };
150745
151119
  }
150746
151120
  var init_apply2 = __esm({
@@ -156811,11 +157185,11 @@ var init_filesystem = __esm({
156811
157185
  await this.closeAfter([duty], async () => {
156812
157186
  const stat5 = await handle.stat({ bigint: true });
156813
157187
  requireFact(stat5.isFile() && Number(stat5.uid) === process.getuid?.(), "OWNERSHIP_UNCERTAIN");
156814
- let written = 0;
156815
- while (written < bytes.length) {
156816
- const value = await handle.write(bytes, written, bytes.length - written, written);
157188
+ let written2 = 0;
157189
+ while (written2 < bytes.length) {
157190
+ const value = await handle.write(bytes, written2, bytes.length - written2, written2);
156817
157191
  requireFact(value.bytesWritten > 0, "IO_FAILED");
156818
- written += value.bytesWritten;
157192
+ written2 += value.bytesWritten;
156819
157193
  }
156820
157194
  await handle.sync();
156821
157195
  requireFact(
@@ -157375,19 +157749,19 @@ var init_filesystem = __esm({
157375
157749
  );
157376
157750
  if (reservation) await this.checkReservation(reservation);
157377
157751
  await observe(bytes);
157378
- let written = 0;
157379
- while (written < copy2.byteLength) {
157752
+ let written2 = 0;
157753
+ while (written2 < copy2.byteLength) {
157380
157754
  const value = await original.write(
157381
157755
  copy2,
157382
- written,
157383
- copy2.byteLength - written,
157384
- bytes + written
157756
+ written2,
157757
+ copy2.byteLength - written2,
157758
+ bytes + written2
157385
157759
  );
157386
157760
  requireFact(value.bytesWritten > 0, "IO_FAILED");
157387
- written += value.bytesWritten;
157761
+ written2 += value.bytesWritten;
157388
157762
  }
157389
- bytes += written;
157390
- diagnosticBudget.bytes += written;
157763
+ bytes += written2;
157764
+ diagnosticBudget.bytes += written2;
157391
157765
  hash3.update(copy2);
157392
157766
  expected = await observe(bytes, true);
157393
157767
  })
@@ -158741,11 +159115,11 @@ function createInstallationTransaction(configuration, dependencies, generation3)
158741
159115
  });
158742
159116
  recordBytes(journal, INSTALLATION_LIMITS.journalBytes);
158743
159117
  check4(bounds, options.signal);
158744
- const written = await fs40.writeReuseJournal(reservation, attempt, journal);
158745
- require2(written.path === join56(attempt.attemptRoot, "reuse.json") && written.sha256 === sha2562(recordBytes(journal, INSTALLATION_LIMITS.journalBytes)), "OWNERSHIP_UNCERTAIN");
159118
+ const written2 = await fs40.writeReuseJournal(reservation, attempt, journal);
159119
+ require2(written2.path === join56(attempt.attemptRoot, "reuse.json") && written2.sha256 === sha2562(recordBytes(journal, INSTALLATION_LIMITS.journalBytes)), "OWNERSHIP_UNCERTAIN");
158746
159120
  const unchanged = await fs40.inspectExisting({ signal: options.signal });
158747
159121
  require2(canonicalDigest(unchanged.current) === canonicalDigest(reserved.current) && canonicalDigest(unchanged.installation) === canonicalDigest(reserved.installation), "ROOT_CHANGED");
158748
- journalDigest = written.sha256;
159122
+ journalDigest = written2.sha256;
158749
159123
  currentManifestDigest = reserved.installation.current.pointer.manifestDigest;
158750
159124
  } else {
158751
159125
  await owner("publishing");
@@ -166798,7 +167172,7 @@ var init_default_owner = __esm({
166798
167172
  init_tigris_session();
166799
167173
  init_provider_process();
166800
167174
  init_health();
166801
- FLY_GUIDE_URL = repoUrl("/blob/main/apps/community/FLY.md");
167175
+ FLY_GUIDE_URL = repoUrl("/blob/main/apps/space/FLY.md");
166802
167176
  }
166803
167177
  });
166804
167178
 
@@ -170441,18 +170815,18 @@ function createStdinPrompt(raw) {
170441
170815
  password: async () => next()
170442
170816
  };
170443
170817
  }
170444
- function findOwnerUser(db) {
170445
- const owner = db.select({ id: user.id, email: user.email }).from(user).where(eq(user.role, "owner")).limit(1).get();
170818
+ function findOwnerUser(db2) {
170819
+ const owner = db2.select({ id: user.id, email: user.email }).from(user).where(eq(user.role, "owner")).limit(1).get();
170446
170820
  if (owner) return owner;
170447
- const all = db.select({ id: user.id, email: user.email }).from(user).limit(2).all();
170821
+ const all = db2.select({ id: user.id, email: user.email }).from(user).limit(2).all();
170448
170822
  return all.length === 1 ? all[0] : void 0;
170449
170823
  }
170450
170824
  function errorMessage(err) {
170451
170825
  return err instanceof Error ? err.message : String(err);
170452
170826
  }
170453
170827
  async function runAuthEnable(deps) {
170454
- const { db, auth, configStore, prompt: prompt2, io, options } = deps;
170455
- const existing = db.select({ id: user.id }).from(user).limit(1).get();
170828
+ const { db: db2, auth, configStore, prompt: prompt2, io, options } = deps;
170829
+ const existing = db2.select({ id: user.id }).from(user).limit(1).get();
170456
170830
  if (existing) {
170457
170831
  io.error("An owner account already exists for this DorkOS instance.");
170458
170832
  io.error("To reset its password, run: dorkos auth reset-password");
@@ -170477,16 +170851,23 @@ async function runAuthEnable(deps) {
170477
170851
  io.error(`Could not create the owner account: ${errorMessage(err)}`);
170478
170852
  return 1;
170479
170853
  }
170480
- if (signUpToken) await (await auth.$context).internalAdapter.deleteSession(signUpToken);
170481
170854
  configStore.setDot("auth.enabled", true);
170855
+ if (signUpToken) {
170856
+ try {
170857
+ await (await auth.$context).internalAdapter.deleteSession(signUpToken);
170858
+ } catch (err) {
170859
+ io.error(`Could not end the sign-in made during setup: ${errorMessage(err)}`);
170860
+ io.error("It ends the next time DorkOS starts.");
170861
+ }
170862
+ }
170482
170863
  io.log(`Owner account created for ${email3}.`);
170483
170864
  io.log("This computer now asks for a password too. Other devices always do.");
170484
170865
  io.log("Restart any running DorkOS server for the change to take effect.");
170485
170866
  return 0;
170486
170867
  }
170487
170868
  async function runAuthResetPassword(deps) {
170488
- const { db, auth, prompt: prompt2, io, options } = deps;
170489
- const owner = findOwnerUser(db);
170869
+ const { db: db2, auth, prompt: prompt2, io, options } = deps;
170870
+ const owner = findOwnerUser(db2);
170490
170871
  if (!owner) {
170491
170872
  io.error("No owner account found. Run `dorkos auth enable` first.");
170492
170873
  return 1;
@@ -170520,7 +170901,7 @@ async function runAuthResetPassword(deps) {
170520
170901
  password: hashedPassword
170521
170902
  });
170522
170903
  }
170523
- const signedOut = db.delete(session).where(eq(session.userId, owner.id)).run().changes;
170904
+ const signedOut = db2.delete(session).where(eq(session.userId, owner.id)).run().changes;
170524
170905
  io.log(`Password reset for ${owner.email}.`);
170525
170906
  io.log(
170526
170907
  `Signed out everywhere (${signedOut} ${signedOut === 1 ? "sign-in" : "sign-ins"} ended). Sign in again with the new password.`
@@ -170539,7 +170920,7 @@ var init_auth_commands = __esm({
170539
170920
  });
170540
170921
 
170541
170922
  // src/commands/auth-instance.ts
170542
- function createOwnerAuth(db, secret) {
170923
+ function createOwnerAuth(db2, secret) {
170543
170924
  return betterAuth({
170544
170925
  appName: "DorkOS",
170545
170926
  // The signing secret is the one identity-relevant option beyond the hash +
@@ -170551,7 +170932,7 @@ function createOwnerAuth(db, secret) {
170551
170932
  // `auth.api.*` / `auth.$context` in-process, so there is no request origin
170552
170933
  // to check and no cookie to sign. Better Auth logs a one-time "Base URL is
170553
170934
  // not set" advisory here — expected and harmless.
170554
- database: drizzleAdapter(db, {
170935
+ database: drizzleAdapter(db2, {
170555
170936
  provider: "sqlite",
170556
170937
  schema: { user, session, account, verification, apikey }
170557
170938
  }),
@@ -170572,7 +170953,7 @@ function createOwnerAuth(db, secret) {
170572
170953
  user: {
170573
170954
  create: {
170574
170955
  before: async (userData) => {
170575
- const existing = db.select({ id: user.id }).from(user).limit(1).get();
170956
+ const existing = db2.select({ id: user.id }).from(user).limit(1).get();
170576
170957
  if (existing) {
170577
170958
  throw new APIError2("FORBIDDEN", {
170578
170959
  code: "REGISTRATION_CLOSED",
@@ -170658,15 +171039,15 @@ function toGrant(value) {
170658
171039
  }
170659
171040
  return { id, agentPath, capabilityId, expiresAt };
170660
171041
  }
170661
- function captureLiveStandingGrants(db, dorkHome, logger3, licence, now3 = /* @__PURE__ */ new Date()) {
171042
+ function captureLiveStandingGrants(db2, dorkHome, logger3, licence, now3 = /* @__PURE__ */ new Date()) {
170662
171043
  try {
170663
171044
  if (!licence.honored) return 0;
170664
- const table2 = db.get(
171045
+ const table2 = db2.get(
170665
171046
  sql2`SELECT name FROM sqlite_master WHERE type = 'table' AND name = 'approval_grants'`
170666
171047
  );
170667
171048
  if (!table2) return 0;
170668
171049
  const floor = licence.voidBefore ?? "";
170669
- const rows = db.all(
171050
+ const rows = db2.all(
170670
171051
  sql2`SELECT id, agent_path, capability_id, expires_at FROM approval_grants
170671
171052
  WHERE revoked_at IS NULL AND expires_at > ${now3.toISOString()}
170672
171053
  AND granted_at > ${floor}`
@@ -170767,15 +171148,15 @@ import { mkdirSync as mkdirSync8, readFileSync as readFileSync23 } from "node:fs
170767
171148
  import { input as input2, password as passwordPrompt } from "@inquirer/prompts";
170768
171149
  async function buildAuthRuntime(dorkHome) {
170769
171150
  mkdirSync8(dorkHome, { recursive: true });
170770
- const db = createDb(path58.join(dorkHome, "dork.db"));
171151
+ const db2 = createDb(path58.join(dorkHome, "dork.db"));
170771
171152
  const { captureLiveStandingGrants: captureLiveStandingGrants2, readStandingGrantLicence: readStandingGrantLicence2 } = await Promise.resolve().then(() => (init_ended_standing_grants(), ended_standing_grants_exports));
170772
- captureLiveStandingGrants2(db, dorkHome, console, readStandingGrantLicence2(dorkHome));
170773
- runMigrations(db);
171153
+ captureLiveStandingGrants2(db2, dorkHome, console, readStandingGrantLicence2(dorkHome));
171154
+ runMigrations(db2);
170774
171155
  const { resolveBetterAuthSecret: resolveBetterAuthSecret2 } = await Promise.resolve().then(() => (init_secret(), secret_exports));
170775
- const auth = createOwnerAuth(db, resolveBetterAuthSecret2(dorkHome));
171156
+ const auth = createOwnerAuth(db2, resolveBetterAuthSecret2(dorkHome));
170776
171157
  const { initConfigManager: initConfigManager2 } = await Promise.resolve().then(() => (init_config_manager(), config_manager_exports));
170777
171158
  const configStore = initConfigManager2(dorkHome);
170778
- return { auth, db, configStore };
171159
+ return { auth, db: db2, configStore };
170779
171160
  }
170780
171161
  function createInteractivePrompt() {
170781
171162
  return {
@@ -170847,11 +171228,11 @@ async function runAuthDispatcher(dorkHome, subcommand2, subArgs) {
170847
171228
  console.log(ENABLE_HELP);
170848
171229
  return 0;
170849
171230
  }
170850
- const { auth, db, configStore } = await buildAuthRuntime(dorkHome);
171231
+ const { auth, db: db2, configStore } = await buildAuthRuntime(dorkHome);
170851
171232
  return await runAuthEnable({
170852
171233
  options,
170853
171234
  auth,
170854
- db,
171235
+ db: db2,
170855
171236
  configStore,
170856
171237
  prompt: resolveCredentialPrompt(),
170857
171238
  io: consoleIo
@@ -170863,11 +171244,11 @@ async function runAuthDispatcher(dorkHome, subcommand2, subArgs) {
170863
171244
  console.log(RESET_HELP);
170864
171245
  return 0;
170865
171246
  }
170866
- const { auth, db } = await buildAuthRuntime(dorkHome);
171247
+ const { auth, db: db2 } = await buildAuthRuntime(dorkHome);
170867
171248
  return await runAuthResetPassword({
170868
171249
  options,
170869
171250
  auth,
170870
- db,
171251
+ db: db2,
170871
171252
  prompt: resolveCredentialPrompt(),
170872
171253
  io: consoleIo
170873
171254
  });
@@ -173113,6 +173494,7 @@ Examples:
173113
173494
  // src/commands/permission-undo-rows.ts
173114
173495
  function valueText(value, key, labels) {
173115
173496
  if (key.kind === "chat") return chatModeWord(value);
173497
+ if (key.kind === "account") return autoMoveWord(value);
173116
173498
  if (value === null) return "not set";
173117
173499
  const words = key.kind === "files" ? labels.stop : key.kind === "preset" ? labels.preset : labels.state;
173118
173500
  return words[value] ?? value;
@@ -173127,6 +173509,8 @@ function settingText(key) {
173127
173509
  return `files${key.runtime ? ` (${key.runtime})` : ""}`;
173128
173510
  case "chat":
173129
173511
  return `chat ${key.sessionId.slice(0, 8)}`;
173512
+ case "account":
173513
+ return `account ${key.accountName}`;
173130
173514
  case "preset":
173131
173515
  return "preset";
173132
173516
  }
@@ -175911,12 +176295,12 @@ function isServerRunning(port2) {
175911
176295
  async function findProjectPaths(dbPath) {
175912
176296
  try {
175913
176297
  const { default: Database3 } = await import("better-sqlite3");
175914
- const db = new Database3(dbPath, { readonly: true });
176298
+ const db2 = new Database3(dbPath, { readonly: true });
175915
176299
  try {
175916
- const rows = db.prepare("SELECT DISTINCT project_path FROM agents").all();
176300
+ const rows = db2.prepare("SELECT DISTINCT project_path FROM agents").all();
175917
176301
  return rows.map((r3) => r3.project_path).filter((p) => fs37.existsSync(path62.join(p, ".dork")));
175918
176302
  } finally {
175919
- db.close();
176303
+ db2.close();
175920
176304
  }
175921
176305
  } catch {
175922
176306
  return [];
@@ -177303,7 +177687,7 @@ if (process.argv[2] === "community") {
177303
177687
  );
177304
177688
  Object.assign(childEnv, credentialEnv.pickCommunityCredentialEnv(rawProcessEnv));
177305
177689
  const exitCode = await dispatcher.runCommunityDispatcher(process.argv.slice(3), {
177306
- cliVersion: "0.124.0",
177690
+ cliVersion: "0.124.1",
177307
177691
  dorkHome: DORK_HOME,
177308
177692
  processEnv: childEnv,
177309
177693
  parseRelease: (bytes) => releaseContract.parseCompatibleCommunityReleaseManifest(
@@ -177321,7 +177705,7 @@ if (process.argv[2] === "community") {
177321
177705
  process.exit(1);
177322
177706
  }
177323
177707
  }
177324
- var cliErrorReporter = initCliErrorReporting({ dorkHome: DORK_HOME, version: "0.124.0" });
177708
+ var cliErrorReporter = initCliErrorReporting({ dorkHome: DORK_HOME, version: "0.124.1" });
177325
177709
  var uninstallCliErrorHandlers = cliErrorReporter ? installCliErrorHandlers(cliErrorReporter) : void 0;
177326
177710
  if (process.argv[2] === "doctor") {
177327
177711
  process.env.DORK_HOME = DORK_HOME;
@@ -177331,7 +177715,7 @@ if (process.argv[2] === "doctor") {
177331
177715
  if (process.argv[2] === "feedback") {
177332
177716
  process.env.DORK_HOME = DORK_HOME;
177333
177717
  const { runFeedback: runFeedback2 } = await Promise.resolve().then(() => (init_feedback2(), feedback_exports));
177334
- process.exit(await runFeedback2(DORK_HOME, "0.124.0", process.argv.slice(3)));
177718
+ process.exit(await runFeedback2(DORK_HOME, "0.124.1", process.argv.slice(3)));
177335
177719
  }
177336
177720
  if (process.argv[2] === "auth") {
177337
177721
  process.env.DORK_HOME = DORK_HOME;
@@ -177430,7 +177814,7 @@ if (process.argv[2] === "agent" || process.argv[2] === "task" || process.argv[2]
177430
177814
  }
177431
177815
  }
177432
177816
  const { runVersionDispatcher: runVersionDispatcher2 } = await Promise.resolve().then(() => (init_version5(), version_exports));
177433
- process.exit(await runVersionDispatcher2("0.124.0", DORK_HOME, subArgs));
177817
+ process.exit(await runVersionDispatcher2("0.124.1", DORK_HOME, subArgs));
177434
177818
  }
177435
177819
  var { values, positionals } = parseCliArgs();
177436
177820
  if (positionals[0] && !knownCommands.has(positionals[0])) {
@@ -177524,14 +177908,14 @@ Examples:
177524
177908
  process.exit(0);
177525
177909
  }
177526
177910
  if (values.version) {
177527
- console.log("0.124.0");
177911
+ console.log("0.124.1");
177528
177912
  process.exit(0);
177529
177913
  }
177530
177914
  if (values["post-install-check"]) {
177531
177915
  const claudeFound = checkClaude();
177532
177916
  const coreExtensionsFound = checkCoreExtensions();
177533
177917
  const extensionsCompile = await checkExtensionCompilation();
177534
- console.log(`dorkos ${"0.124.0"}`);
177918
+ console.log(`dorkos ${"0.124.1"}`);
177535
177919
  if (!coreExtensionsFound) {
177536
177920
  console.log("Installation incomplete \u2014 bundled core extensions are missing.");
177537
177921
  }
@@ -177679,7 +178063,7 @@ if (fs39.existsSync(envPath)) {
177679
178063
  }
177680
178064
  uninstallCliErrorHandlers?.();
177681
178065
  process.env.DORKOS_CLI_ENTRYPOINT = fileURLToPath7(import.meta.url);
177682
- process.env.DORKOS_CLI_VERSION = "0.124.0";
178066
+ process.env.DORKOS_CLI_VERSION = "0.124.1";
177683
178067
  var server;
177684
178068
  try {
177685
178069
  server = await import("../server/index.js");
@@ -177704,7 +178088,7 @@ var ansiReset = "\x1B[0m";
177704
178088
  console.log("");
177705
178089
  console.log(`${purple}${logo}${ansiReset}`);
177706
178090
  console.log("");
177707
- console.log(` DorkOS v${"0.124.0"}`);
178091
+ console.log(` DorkOS v${"0.124.1"}`);
177708
178092
  console.log(` Local: ${link(localUrl, localUrl)}`);
177709
178093
  var nets = networkInterfaces();
177710
178094
  var networkUrl = null;
@@ -177730,9 +178114,9 @@ if (shouldOpenBrowser && process.stdin.isTTY) {
177730
178114
  const openCmd = process.platform === "darwin" ? "open" : process.platform === "win32" ? "start" : "xdg-open";
177731
178115
  exec(`${openCmd} ${localUrl}`);
177732
178116
  }
177733
- checkForUpdate("0.124.0").then((latestVersion) => {
178117
+ checkForUpdate("0.124.1").then((latestVersion) => {
177734
178118
  if (latestVersion) {
177735
- const msg = `Update available: ${"0.124.0"} \u2192 ${latestVersion}`;
178119
+ const msg = `Update available: ${"0.124.1"} \u2192 ${latestVersion}`;
177736
178120
  const cmd = "Run npm install -g dorkos@latest to update";
177737
178121
  const width = Math.max(msg.length, cmd.length) + 6;
177738
178122
  const pad2 = (s2) => `\u2502 ${s2}${" ".repeat(width - s2.length - 6)} \u2502`;