mirror of
https://github.com/jbranchaud/til
synced 2026-01-03 15:18:01 +00:00
Fix a typo in the latest til
This commit is contained in:
@@ -29,7 +29,7 @@ thrown. We can simultaneously avoid a bunch of exception handling logic and
|
||||
provide a default value with the `_.get` function:
|
||||
|
||||
```javascript
|
||||
_.get(resp, 'resp.error.errors[0].message', 'Default error message');
|
||||
_.get(resp, 'error.errors[0].message', 'Default error message');
|
||||
```
|
||||
|
||||
If we decide to not include a default value, then `undefined` will be used.
|
||||
|
||||
Reference in New Issue
Block a user