mirror of
https://github.com/withastro/astro.git
synced 2025-02-17 22:44:24 -05:00
[ci] format
This commit is contained in:
parent
16f12e426e
commit
87f36d4074
1 changed files with 1 additions and 4 deletions
|
@ -22,10 +22,7 @@ export function requestHasLocale(locales: Locales) {
|
||||||
export function requestIs404Or500(request: Request, base = '') {
|
export function requestIs404Or500(request: Request, base = '') {
|
||||||
const url = new URL(request.url);
|
const url = new URL(request.url);
|
||||||
|
|
||||||
return (
|
return url.pathname.startsWith(`${base}/404`) || url.pathname.startsWith(`${base}/500`);
|
||||||
url.pathname.startsWith(`${base}/404`) ||
|
|
||||||
url.pathname.startsWith(`${base}/500`)
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
// Checks if the pathname has any locale
|
// Checks if the pathname has any locale
|
||||||
export function pathHasLocale(path: string, locales: Locales): boolean {
|
export function pathHasLocale(path: string, locales: Locales): boolean {
|
||||||
|
|
Loading…
Add table
Reference in a new issue