Skip to content
This repository was archived by the owner on Jun 7, 2023. It is now read-only.

Commit 48d7ff4

Browse files
committed
Add more data to the console on a 422 error
1 parent d441ab6 commit 48d7ff4

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

runestone/common/js/runestonebase.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,11 @@ export default class RunestoneBase {
135135
try {
136136
let response = await fetch(request);
137137
if (!response.ok) {
138+
if (response.status === 422) {
139+
// Get details about why this is unprocesable.
140+
post_return = await response.json()
141+
console.log(post_return.detail)
142+
}
138143
throw new Error("Failed to save the log entry");
139144
}
140145
post_return = response.json();

0 commit comments

Comments
 (0)