@base44-preview/cli 0.0.50-pr.475.2394181 → 0.0.50-pr.475.60b9330

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.
package/dist/cli/index.js CHANGED
@@ -243211,6 +243211,7 @@ var package_default = {
243211
243211
  "@types/ejs": "^3.1.5",
243212
243212
  "@types/express": "^5.0.6",
243213
243213
  "@types/json-schema": "^7.0.15",
243214
+ "@types/jsonwebtoken": "^9.0.10",
243214
243215
  "@types/lodash": "^4.17.24",
243215
243216
  "@types/multer": "^2.0.0",
243216
243217
  "@types/node": "^22.10.5",
@@ -243229,6 +243230,7 @@ var package_default = {
243229
243230
  globby: "^16.1.0",
243230
243231
  "http-proxy-middleware": "^3.0.5",
243231
243232
  "json-schema-to-typescript": "^15.0.4",
243233
+ jsonwebtoken: "^9.0.3",
243232
243234
  json5: "^2.2.3",
243233
243235
  ky: "^1.14.2",
243234
243236
  lodash: "^4.17.23",
@@ -253522,7 +253524,7 @@ function createAuthRouter(db2, logger2) {
253522
253524
  const privateUserData = await privateUserCollection?.findOneAsync({
253523
253525
  email: email3
253524
253526
  });
253525
- const otpCode = privateUserData ? privateUserData.otpCode : generateCode();
253527
+ const otpCode = generateCode();
253526
253528
  const id2 = privateUserData ? privateUserData.id : nanoid3();
253527
253529
  if (!privateUserData) {
253528
253530
  await privateUserCollection?.insertAsync({
@@ -253532,6 +253534,15 @@ function createAuthRouter(db2, logger2) {
253532
253534
  password,
253533
253535
  createdAt: Date.now()
253534
253536
  });
253537
+ } else {
253538
+ await privateUserCollection?.updateAsync({
253539
+ email: email3
253540
+ }, {
253541
+ $set: {
253542
+ otpCode,
253543
+ createdAt: Date.now()
253544
+ }
253545
+ });
253535
253546
  }
253536
253547
  logger2.log(theme.styles.info(`
253537
253548
  In order to complete registration use this verification code: ${otpCode}
@@ -260384,4 +260395,4 @@ export {
260384
260395
  CLIExitError
260385
260396
  };
260386
260397
 
260387
- //# debugId=033335773979C1A464756E2164756E21
260398
+ //# debugId=8BC0D7129D49BDE164756E2164756E21