mirror of
https://github.com/yattee/yattee.git
synced 2026-05-12 02:17:46 +00:00
Surface clearer error when adding a Piped frontend URL
Pointing AddRemoteServer at a Piped Vue SPA (e.g. the frontend host rather than the API host) used to fail with a generic "could not detect instance type" — every JSON probe got the same index.html back. On the failure path, fetch `/` once more and look for `<title>Piped</title>`; if matched, return a new `pipedFrontendDetected` error that tells the user to enter the Piped API URL instead.
This commit is contained in:
@@ -15094,6 +15094,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"sources.error.pipedFrontendDetected" : {
|
||||
"comment" : "Error when the URL points to the Piped web frontend (SPA) instead of its API backend. The frontend serves the same index.html for every path so detection cannot succeed.",
|
||||
"localizations" : {
|
||||
"en" : {
|
||||
"stringUnit" : {
|
||||
"state" : "translated",
|
||||
"value" : "This URL is the Piped web frontend, not its API. Please enter the Piped API URL instead (for example, the frontend may be at piped.example.com while the API is at piped-api.example.com or pipedapi.example.com — check with the instance operator)."
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"sources.error.couldNotDetect" : {
|
||||
"comment" : "Error when source type could not be detected",
|
||||
"localizations" : {
|
||||
|
||||
Reference in New Issue
Block a user