Skip to content

Commit

Permalink
VERY IMPORTANT FIX
Browse files Browse the repository at this point in the history
  • Loading branch information
Melkiades committed Oct 16, 2023
1 parent ca83046 commit 76bfada
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion R/tostring.R
Original file line number Diff line number Diff line change
Expand Up @@ -754,8 +754,12 @@ wrap_string <- function(str, width, collapse = NULL, smart = TRUE) {
paste0(ret[we_interval], collapse = " "),
width
)
# Taking out repetitions if there are more than one
if (length(we_interval) > 1) {
ret <- ret[-we_interval[-1]]
}
# Paste together and rerun
ret <- paste0(unique(ret), collapse = " ")
ret <- paste0(ret, collapse = " ")
return(wrap_string(str = ret, width = width, collapse = collapse, smart = smart))
}
} else {
Expand Down

0 comments on commit 76bfada

Please sign in to comment.