next-openapi-gen 1.0.5 → 1.0.6
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.js +3 -1
- package/dist/index.js +3 -1
- package/dist/next/index.js +3 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -16269,12 +16269,14 @@ var NextFrameworkSource = class {
|
|
|
16269
16269
|
}
|
|
16270
16270
|
getScanRoots() {
|
|
16271
16271
|
const roots = [this.config.apiDir];
|
|
16272
|
+
const resolvedApiDir = path22.resolve(this.config.apiDir);
|
|
16272
16273
|
const candidateRoots = [
|
|
16273
16274
|
path22.join(process.cwd(), "src", "app", "api"),
|
|
16274
16275
|
path22.join(process.cwd(), "app", "api")
|
|
16275
16276
|
];
|
|
16276
16277
|
candidateRoots.forEach((candidateRoot) => {
|
|
16277
|
-
|
|
16278
|
+
const resolvedCandidate = path22.resolve(candidateRoot);
|
|
16279
|
+
if (fs17.existsSync(candidateRoot) && resolvedCandidate !== resolvedApiDir && !resolvedApiDir.startsWith(resolvedCandidate + path22.sep) && !roots.includes(candidateRoot)) {
|
|
16278
16280
|
roots.push(candidateRoot);
|
|
16279
16281
|
}
|
|
16280
16282
|
});
|
package/dist/index.js
CHANGED
|
@@ -15971,12 +15971,14 @@ var NextFrameworkSource = class {
|
|
|
15971
15971
|
}
|
|
15972
15972
|
getScanRoots() {
|
|
15973
15973
|
const roots = [this.config.apiDir];
|
|
15974
|
+
const resolvedApiDir = path19.resolve(this.config.apiDir);
|
|
15974
15975
|
const candidateRoots = [
|
|
15975
15976
|
path19.join(process.cwd(), "src", "app", "api"),
|
|
15976
15977
|
path19.join(process.cwd(), "app", "api")
|
|
15977
15978
|
];
|
|
15978
15979
|
candidateRoots.forEach((candidateRoot) => {
|
|
15979
|
-
|
|
15980
|
+
const resolvedCandidate = path19.resolve(candidateRoot);
|
|
15981
|
+
if (fs15.existsSync(candidateRoot) && resolvedCandidate !== resolvedApiDir && !resolvedApiDir.startsWith(resolvedCandidate + path19.sep) && !roots.includes(candidateRoot)) {
|
|
15980
15982
|
roots.push(candidateRoot);
|
|
15981
15983
|
}
|
|
15982
15984
|
});
|
package/dist/next/index.js
CHANGED
|
@@ -1938,12 +1938,14 @@ var NextFrameworkSource = class {
|
|
|
1938
1938
|
}
|
|
1939
1939
|
getScanRoots() {
|
|
1940
1940
|
const roots = [this.config.apiDir];
|
|
1941
|
+
const resolvedApiDir = path5.resolve(this.config.apiDir);
|
|
1941
1942
|
const candidateRoots = [
|
|
1942
1943
|
path5.join(process.cwd(), "src", "app", "api"),
|
|
1943
1944
|
path5.join(process.cwd(), "app", "api")
|
|
1944
1945
|
];
|
|
1945
1946
|
candidateRoots.forEach((candidateRoot) => {
|
|
1946
|
-
|
|
1947
|
+
const resolvedCandidate = path5.resolve(candidateRoot);
|
|
1948
|
+
if (fs5.existsSync(candidateRoot) && resolvedCandidate !== resolvedApiDir && !resolvedApiDir.startsWith(resolvedCandidate + path5.sep) && !roots.includes(candidateRoot)) {
|
|
1947
1949
|
roots.push(candidateRoot);
|
|
1948
1950
|
}
|
|
1949
1951
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "next-openapi-gen",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.6",
|
|
4
4
|
"description": "Automatically generate OpenAPI 3.0, 3.1, and 3.2 documentation from Next.js projects, with support for Zod schemas, TypeScript types, and reusable OpenAPI fragments.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"api",
|