Symptom
Adding a track to a playlist crashes with Cannot read properties of undefined (reading 'clientName'). The error handler fails instead of producing a formatted error message.
What you know
The PlaylistApiClient extends BaseApiClient. The addTrack method calls an API and uses a .catch() handler to format errors. The error handler accesses this.clientName, but this is undefined when it runs.
Hints
TypeScript
TypeScript ready
Test Output
▶
Click "Run Tests" to execute your code