mirror of
https://github.com/jbranchaud/til
synced 2026-01-03 23:28:02 +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:
|
provide a default value with the `_.get` function:
|
||||||
|
|
||||||
```javascript
|
```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.
|
If we decide to not include a default value, then `undefined` will be used.
|
||||||
|
|||||||
Reference in New Issue
Block a user