Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add check if value exists #60

Merged
merged 3 commits into from Mar 21, 2022
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion index.js
Expand Up @@ -78,7 +78,7 @@ const destroyCircular = ({
}

// TODO: Use `stream.isReadable()` when targeting Node.js 18.
if (typeof value === 'object' && typeof value.pipe === 'function') {
if (typeof value === 'object' && value && typeof value.pipe === 'function') {
rj-david marked this conversation as resolved.
Show resolved Hide resolved
to[key] = '[object Stream]';
continue;
}
Expand Down