create-prisma-php-app 1.6.50 → 1.6.52

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/index.js CHANGED
@@ -6,7 +6,6 @@ import path from "path";
6
6
  import chalk from "chalk";
7
7
  import prompts from "prompts";
8
8
  import https from "https";
9
- import { exitCode } from "process";
10
9
  const __filename = fileURLToPath(import.meta.url);
11
10
  const __dirname = path.dirname(__filename);
12
11
  let updateAnswer = null;
@@ -350,7 +349,8 @@ async function getAnswer(predefinedAnswers = {}) {
350
349
  const questions = questionsArray;
351
350
  console.log("🚀 ~ questions:", questions);
352
351
  const onCancel = () => {
353
- return false;
352
+ console.log(chalk.red("Operation cancelled by the user."));
353
+ process.exit(0);
354
354
  };
355
355
  try {
356
356
  const response = await prompts(questions, { onCancel });
@@ -444,7 +444,6 @@ async function main() {
444
444
  answer = await getAnswer(predefinedAnswers);
445
445
  if (answer === null) {
446
446
  console.log(chalk.red("Installation cancelled."));
447
- exitCode;
448
447
  return;
449
448
  }
450
449
  updateAnswer = {
@@ -460,7 +459,6 @@ async function main() {
460
459
  }
461
460
  if (answer === null) {
462
461
  console.log(chalk.red("Installation cancelled."));
463
- exitCode;
464
462
  return;
465
463
  }
466
464
  // execSync(`npm install -g create-prisma-php-app`, { stdio: "inherit" }); // TODO: Uncomment this line before publishing the package
@@ -41,7 +41,7 @@ async function getAnswer() {
41
41
  },
42
42
  ];
43
43
  const onCancel = () => {
44
- return false;
44
+ process.exit(0);
45
45
  };
46
46
  const response = await prompts(questions, { onCancel });
47
47
  if (Object.keys(response).length === 0) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-prisma-php-app",
3
- "version": "1.6.50",
3
+ "version": "1.6.52",
4
4
  "description": "Prisma-PHP: A Revolutionary Library Bridging PHP with Prisma ORM",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",