Skip to content

Commit d554b8a

Browse files
LekoMylesBorins
authored andcommitted
doc: Add example of null to assert.ifError
PR-URL: #18236 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Michaël Zasso <[email protected]>
1 parent 74d86cc commit d554b8a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

doc/api/assert.md

+2
Original file line numberDiff line numberDiff line change
@@ -337,6 +337,8 @@ argument in callbacks.
337337
```js
338338
const assert = require('assert');
339339

340+
assert.ifError(null);
341+
// OK
340342
assert.ifError(0);
341343
// OK
342344
assert.ifError(1);

0 commit comments

Comments
 (0)