create-prisma-php-app 1.26.500 → 1.26.501

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
@@ -130,7 +130,7 @@ async function main() {
130
130
  dependencies.push("swagger-jsdoc", "@types/swagger-jsdoc");
131
131
  }
132
132
  if (answer.swaggerDocs && answer.prisma) {
133
- dependencies.push("prompts", "@types/prompts");
133
+ dependencies.push("prompts", "@types/prompts", "@prisma/internals");
134
134
  }
135
135
  if (answer.tailwindcss) {
136
136
  dependencies.push(
@@ -232,7 +232,8 @@ async function main() {
232
232
  "swagger-jsdoc",
233
233
  "@types/swagger-jsdoc",
234
234
  "prompts",
235
- "@types/prompts"
235
+ "@types/prompts",
236
+ "@prisma/internals"
236
237
  );
237
238
  }
238
239
  if (!updateAnswer.tailwindcss) {
@@ -1,15 +1,10 @@
1
- import { fileURLToPath } from "url";
2
- import { dirname, resolve } from "path";
1
+ import { resolve } from "path";
3
2
  import { readFileSync, writeFileSync } from "fs";
4
- import psdk from "@prisma/sdk"; // Default import of CommonJS module
3
+ import psdk from "@prisma/internals";
4
+ import { getFileMeta } from "./utils.js";
5
5
 
6
- const { getDMMF } = psdk; // Destructure getDMMF from the imported package
7
-
8
- // Polyfill for __dirname in ES modules
9
- const __filename = fileURLToPath(import.meta.url);
10
- const __dirname = dirname(__filename);
11
-
12
- // Load the Prisma schema file
6
+ const { __dirname } = getFileMeta();
7
+ const { getDMMF } = psdk;
13
8
  const schemaPath: string = resolve(__dirname, "../prisma/schema.prisma");
14
9
  const prismaSchemaJsonPath: string = resolve(__dirname, "prisma-schema.json");
15
10
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-prisma-php-app",
3
- "version": "1.26.500",
3
+ "version": "1.26.501",
4
4
  "description": "Prisma-PHP: A Revolutionary Library Bridging PHP with Prisma ORM",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",