mirror of
https://github.com/privacyguides/privacyguides.org.git
synced 2025-05-09 01:35:29 -04:00
42 lines
1 KiB
Text
42 lines
1 KiB
Text
handle_errors {
|
|
@errors `{err.status_code} in [404]`
|
|
handle @errors {
|
|
handle @es {
|
|
try_files /i18n/{err.status_code}.es.html i18n/{err.status_code}.en.html
|
|
file_server
|
|
}
|
|
handle @fr {
|
|
try_files i18n/{err.status_code}.fr.html i18n/{err.status_code}.en.html
|
|
file_server
|
|
}
|
|
handle @he {
|
|
try_files i18n/{err.status_code}.he.html i18n/{err.status_code}.en.html
|
|
file_server
|
|
}
|
|
handle @it {
|
|
try_files i18n/{err.status_code}.it.html i18n/{err.status_code}.en.html
|
|
file_server
|
|
}
|
|
handle @nl {
|
|
try_files i18n/{err.status_code}.nl.html i18n/{err.status_code}.en.html
|
|
file_server
|
|
}
|
|
handle @ru {
|
|
try_files i18n/{err.status_code}.ru.html i18n/{err.status_code}.en.html
|
|
file_server
|
|
}
|
|
handle @zh-Hant {
|
|
try_files i18n/{err.status_code}.zh-Hant.html i18n/{err.status_code}.en.html
|
|
file_server
|
|
}
|
|
handle {
|
|
try_files i18n/{err.status_code}.en.html
|
|
file_server
|
|
}
|
|
}
|
|
|
|
# Handle all other webserver errors with a simple text response
|
|
handle {
|
|
respond "{err.status_code} {err.status_text}"
|
|
}
|
|
}
|