mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2026-11-16 12:18:45 +00:00
use undefined error if the error is not hb
This commit is contained in:
@@ -99,7 +99,8 @@ const VaultPage = (props)=>{
|
|||||||
|
|
||||||
const response = await request.get(`/api/vault/total?title=${title}&author=${author}&v3=${v3}&legacy=${legacy}`)
|
const response = await request.get(`/api/vault/total?title=${title}&author=${author}&v3=${v3}&legacy=${legacy}`)
|
||||||
.catch((error)=>{
|
.catch((error)=>{
|
||||||
console.log('error at loadTotal: ', error);
|
console.log('error at loadTotal: ');
|
||||||
|
console.error(error);
|
||||||
setError(error);
|
setError(error);
|
||||||
updateStateWithBrews([], 1);
|
updateStateWithBrews([], 1);
|
||||||
});
|
});
|
||||||
@@ -441,7 +442,7 @@ const VaultPage = (props)=>{
|
|||||||
if(error.HBErrorCode === undefined) {
|
if(error.HBErrorCode === undefined) {
|
||||||
return (
|
return (
|
||||||
<div className='foundBrews noBrews'>
|
<div className='foundBrews noBrews'>
|
||||||
<h3>{error.toString()}</h3>
|
<h3>Error: Unknown error</h3>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user