feat: log with console.error on notifyApiError (#2646)

* feat: log with `console.error` on `notifyApiError`

usually why have code like that
```
    getAudit() {
      LNbits.api
        .request('GET', '/admin/api/v1/audit',
this.g.user.wallets[0].adminkey)
        .then(response => {
          this.auditData = response.data
          xonst myerror = isSwallowed()
        })
        .catch(function (error) {
          LNbits.utils.notifyApiError(error)
        })
    },

```
which if you make a mistake hides your error. logging console.error here
again makes it easier to see what is happening while developing and
doesnt hurt for the user aswell

* chore: bundle

* fixup!

---------

Co-authored-by: Arc <33088785+arcbtc@users.noreply.github.com>
This commit is contained in:
dni ⚡ 2024-08-30 13:23:11 +02:00 committed by GitHub
parent 209cf7fbe0
commit 6e6b387b7d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 1 deletions

File diff suppressed because one or more lines are too long

View file

@ -323,6 +323,7 @@ window.LNbits = {
return this.formatSat(value / 1000)
},
notifyApiError: function (error) {
console.error(error)
var types = {
400: 'warning',
401: 'warning',