Skip to content

Commit

Permalink
Rename string trim functions (#315)
Browse files Browse the repository at this point in the history
Co-authored-by: Oskar Gewalli <wallymathieu@users.noreply.github.com>
  • Loading branch information
cmeeren and wallymathieu authored Jun 22, 2024
1 parent 50207cf commit 76fbe4c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/FSharpPlus/Extensions/String.fs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ module String =
///
/// Note this is distinct from trim which trims the given characters,
/// not white spaces.
let trimWhiteSpaces (source: string) =
let trim (source: string) =
raiseIfNull (nameof source) source

source.Trim ()
Expand Down Expand Up @@ -151,7 +151,7 @@ module String =
source.PadRight (totalLength, paddingChar)

/// Removes all leading and trailing occurrences of specified characters from the given string.
let trim (trimChars: char seq) (source: string) =
let trimBoth (trimChars: char seq) (source: string) =
raiseIfNull (nameof source) source

source.Trim (Seq.toArray trimChars)
Expand Down

0 comments on commit 76fbe4c

Please sign in to comment.