sparkzen 1.1.1 → 1.1.2

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
@@ -163,7 +163,7 @@ function registerCommands(program2) {
163
163
 
164
164
  // package.json
165
165
  var name = "sparkzen";
166
- var version = "1.1.1";
166
+ var version = "1.1.2";
167
167
 
168
168
  // src/cli/index.ts
169
169
  var program = new Command4();
package/dist/index.js CHANGED
@@ -12,12 +12,12 @@ import path from "path";
12
12
  var getRouteUrl = (filePath) => {
13
13
  const production = process.env.NODE_ENV === "production";
14
14
  const basePath = production ? process.cwd() : path.join(process.cwd(), "src", "routes");
15
- let routePath = filePath.replace(basePath, "").replace(/\\/g, "/").replace(/\.(js|ts)$/, "");
15
+ let routePath = filePath.replace(basePath, "").replaceAll("\\", "/").replace(/\.(js|ts)$/, "");
16
16
  const segments = routePath.split("/");
17
17
  segments.pop();
18
18
  routePath = segments.join("/");
19
19
  routePath = routePath.replace(/\[(\w+)\]/g, ":$1");
20
- return `/api${routePath}`.replace(/\/+/g, "/");
20
+ return `/api${routePath}`.replace(/\/+/g, "/").replaceAll("dist/routes/", "");
21
21
  };
22
22
 
23
23
  // src/core/routing/registerRoute.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sparkzen",
3
- "version": "1.1.1",
3
+ "version": "1.1.2",
4
4
  "license": "MIT",
5
5
  "author": "Matheus dos Santos Paixão",
6
6
  "type": "module",