Skip to content

Commit

Permalink
Merge pull request #4 from woxtu/patch
Browse files Browse the repository at this point in the history
Fix blocklist checking
  • Loading branch information
macmoonshine authored Dec 19, 2023
2 parents 5cb0439 + 63e5ddb commit 73f2347
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/sqids/Sqids.swift
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ public struct Sqids {
return true
}
}
else if word.first!.isNumber {
else if word.contains(where: \.isNumber) {
if id.hasPrefix(word) || id.hasSuffix(word) {
return true
}
Expand Down

0 comments on commit 73f2347

Please sign in to comment.