mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-03-31 16:45:27 +00:00
prefer server message on failure code received
This commit is contained in:
parent
4215fb130d
commit
c4e8f2ff61
1 changed files with 6 additions and 1 deletions
|
|
@ -450,7 +450,12 @@ fn handle(
|
|||
}
|
||||
error => {
|
||||
let status = page.content.to_status_failure();
|
||||
status.set_description(Some(&error.to_string()));
|
||||
status.set_description(
|
||||
Some(&match response.meta.data {
|
||||
Some(message) => message.to_string(),
|
||||
None => error.to_string()
|
||||
})
|
||||
);
|
||||
page.set_progress(0.0);
|
||||
page.set_title(&status.title());
|
||||
redirects.replace(0); // reset
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue