Skip to content

Commit

Permalink
Point to the right argument
Browse files Browse the repository at this point in the history
  • Loading branch information
Genbox committed Jan 21, 2024
1 parent ff3505c commit 023cd26
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Sqids/SqidsEncoder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -71,13 +71,13 @@ public SqidsEncoder(SqidsOptions options)

if (options.Alphabet.Distinct().Count() != options.Alphabet.Length)
throw new ArgumentOutOfRangeException(
nameof(options.MinLength),
nameof(options.Alphabet),
"The alphabet must not contain duplicate characters."
);

if (Encoding.UTF8.GetByteCount(options.Alphabet) != options.Alphabet.Length)
throw new ArgumentOutOfRangeException(
nameof(options.MinLength),
nameof(options.Alphabet),
"The alphabet must not contain multi-byte characters."
);

Expand Down

0 comments on commit 023cd26

Please sign in to comment.