Skip to content

Comments

types(index): allow undefined for some optional properties#158

Merged
Fdawgs merged 2 commits intomasterfrom
types/undefined
Jan 28, 2025
Merged

types(index): allow undefined for some optional properties#158
Fdawgs merged 2 commits intomasterfrom
types/undefined

Conversation

@Fdawgs
Copy link
Member

@Fdawgs Fdawgs commented Jan 28, 2025

This PR updates the types of some optional properties to be undefined, because they check against undefined with nullish coalescing operators and assign defaults:

const strictCredentials = opts.strictCredentials ?? true
const useUtf8 = opts.utf8 ?? true

Checklist

@Fdawgs Fdawgs merged commit 35abdb4 into master Jan 28, 2025
13 checks passed
@Fdawgs Fdawgs deleted the types/undefined branch January 28, 2025 18:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants