MrRefactoring / jira.js

A JavaScript/TypeScript wrapper for the JIRA Cloud, Service Desk and Agile REST API
https://mrrefactoring.github.io/jira.js/
MIT License
349 stars 46 forks source link

Lib throws error Cannot read properties of undefined (reading 'data') when have newErrorHandling is true #215

Closed Moser-ss closed 2 years ago

Moser-ss commented 2 years ago

The lib throws the error Cannot read properties of undefined (reading 'data') when the newErrorHandling is true I believe the issue happens because the error object doesn't contain the response object https://github.com/MrRefactoring/jira.js/blob/master/src/clients/baseClient.ts#L108

MrRefactoring commented 2 years ago

Hi @Moser-ss! Thank you for reporting!

MrRefactoring commented 2 years ago

Should work now (in v2.15.2)