refactor(utils): inline defaults and isArguments helpers#2107
Merged
Conversation
nkaradzhov
approved these changes
May 20, 2026
a02311a to
63aaed1
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Reviewed by Cursor Bugbot for commit 63aaed1. Configure here.
63aaed1 to
fe10102
Compare
|
🎉 This PR is included in version 5.11.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Fixes #2106
Note
Medium Risk
Behavior must stay compatible with lodash.defaults/isarguments across connection parsing, option merging, and auto-pipelining; regressions would affect many code paths, though new unit tests reduce that risk.
Overview
Replaces the runtime dependencies
lodash.defaultsandlodash.isargumentswith in-repo implementations underlib/utils/defaults.tsandlib/utils/isArguments.ts(adapted from es-toolkit compat / Lodash-style behavior, with license headers).lib/utils/lodash.tsnow re-exports those modules instead ofrequireing the npm packages, andisArgumentsis also exported fromlib/utils/index.ts.package.jsondrops the two lodash packages and their@types/*devDependencies;package-lock.jsonreflects the slimmer tree. Unit tests intest/unit/utils.tslock in lodash-like semantics fordefaultsandisArguments(multi-source merge, null vs undefined, iteratee guard,argumentsdetection).Call sites (
Redis,parseURL, cluster helpers, auto-pipelining) keep importing from./utils/lodash—this is primarily a dependency footprint / vendoring change, not a new feature API.Reviewed by Cursor Bugbot for commit dee0b74. Bugbot is set up for automated code reviews on this repo. Configure here.