Skip to content

Commit

Permalink
move comment into right place
Browse files Browse the repository at this point in the history
  • Loading branch information
kbukum1 committed Dec 20, 2024
1 parent 2e7289d commit 47dd89e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion npm_and_yarn/lib/dependabot/npm_and_yarn/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ def initialize(version)

sig { params(version: VersionParameter).returns(VersionParameter) }
def clean_version(version)
# Check if version is a string before attempting to match
if version.is_a?(String)
# Check if version is a string before attempting to match
# Matches @ followed by x.y.z (digits separated by dots)
if (match = version.match(/@(\d+\.\d+\.\d+)/))
version = match[1] # Just "4.5.3"
Expand Down

0 comments on commit 47dd89e

Please sign in to comment.