Rocky_Mountain_Vending/.pnpm-store/v10/files/64/96a009d493778f19faf54a090bcaedd88938362fa42138a9c9d92451a4db5945f15322158fcd8be841d9f7d1083fa7d8cb03b68bc4e5895f355ae0ae1eb0f9
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

12 lines
No EOL
568 B
Text

import { parsePath } from '../shared/lib/router/utils/parse-path';
export function removeLocale(path, locale) {
if (process.env.__NEXT_I18N_SUPPORT) {
const { pathname } = parsePath(path);
const pathLower = pathname.toLowerCase();
const localeLower = locale?.toLowerCase();
return locale && (pathLower.startsWith(`/${localeLower}/`) || pathLower === `/${localeLower}`) ? `${pathname.length === locale.length + 1 ? `/` : ``}${path.slice(locale.length + 1)}` : path;
}
return path;
}
//# sourceMappingURL=remove-locale.js.map