Skip to content

Commit

Permalink
Add error catch for db requests in case it fails
Browse files Browse the repository at this point in the history
  • Loading branch information
Pierstoval committed Nov 18, 2024
1 parent ebf89fc commit eeec426
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions js/glpi_install.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@
success_element.querySelector('button').removeAttribute('disabled');
}
})
.catch(err => message(message_element, `Request error:\n${err.message||err.toString()}`))
.finally(() => {
request_running = false;
});
Expand Down

0 comments on commit eeec426

Please sign in to comment.