Rocky_Mountain_Vending/.pnpm-store/v10/files/8a/8a079c50e38bdabf097b4975f18a58a9f563f69b7e7dda613d9df662fbccf3f1e802fb1dcb2db3fb18581437d0caa992e5757d98ab676f64b358d8fa5139ab
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

62 lines
No EOL
2 KiB
Text

import { parse } from 'next/dist/compiled/stacktrace-parser';
import { decorateServerError } from '../../shared/lib/error-source';
function getFilesystemFrame(frame) {
const f = {
...frame
};
if (typeof f.file === 'string') {
if (// Posix:
f.file.startsWith('/') || // Win32:
/^[a-z]:\\/i.test(f.file) || // Win32 UNC:
f.file.startsWith('\\\\')) {
f.file = `file://${f.file}`;
}
}
return f;
}
export function getServerError(error, type) {
if (error.name === 'TurbopackInternalError') {
// If this is an internal Turbopack error we shouldn't show internal details
// to the user. These are written to a log file instead.
const turbopackInternalError = Object.defineProperty(new Error('An unexpected Turbopack error occurred. Please see the output of `next dev` for more details.'), "__NEXT_ERROR_CODE", {
value: "E167",
enumerable: false,
configurable: true
});
decorateServerError(turbopackInternalError, type);
return turbopackInternalError;
}
let n;
try {
throw Object.defineProperty(new Error(error.message), "__NEXT_ERROR_CODE", {
value: "E394",
enumerable: false,
configurable: true
});
} catch (e) {
n = e;
}
n.name = error.name;
try {
n.stack = `${n.toString()}\n${parse(error.stack).map(getFilesystemFrame).map((f)=>{
let str = ` at ${f.methodName}`;
if (f.file) {
let loc = f.file;
if (f.lineNumber) {
loc += `:${f.lineNumber}`;
if (f.column) {
loc += `:${f.column}`;
}
}
str += ` (${loc})`;
}
return str;
}).join('\n')}`;
} catch {
n.stack = error.stack;
}
decorateServerError(n, type);
return n;
}
//# sourceMappingURL=node-stack-frames.js.map