Fix route index JavaScript rendering
This commit is contained in:
@@ -429,7 +429,7 @@ Route::get('/', function () {
|
|||||||
const token = tokenInput.value.trim();
|
const token = tokenInput.value.trim();
|
||||||
|
|
||||||
if ((authType === 'jwt' || authType === 'diagnostic') && token) {
|
if ((authType === 'jwt' || authType === 'diagnostic') && token) {
|
||||||
headers.Authorization = `Bearer ${token}`;
|
headers.Authorization = 'Bearer ' + token;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((authType === 'jwt' || authType === 'diagnostic') && !token) {
|
if ((authType === 'jwt' || authType === 'diagnostic') && !token) {
|
||||||
@@ -445,7 +445,7 @@ Route::get('/', function () {
|
|||||||
? JSON.stringify(await response.json(), null, 2)
|
? JSON.stringify(await response.json(), null, 2)
|
||||||
: await response.text();
|
: await response.text();
|
||||||
|
|
||||||
showResult(url, `${response.status} ${response.statusText}`, body);
|
showResult(url, response.status + ' ' + response.statusText, body);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
showResult(url, 'Erro', error.message);
|
showResult(url, 'Erro', error.message);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user