Skip to content

Commit

Permalink
avoid warning
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentarelbundock committed Apr 7, 2024
1 parent c130320 commit fff94f5
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions R/settings_docute.R
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,10 @@
tmp <- sprintf("{title: '%s', link: '%s'}", titles, fn_vignettes)
tmp <- paste(tmp, collapse = ", ")
sidebar <- paste(sidebar, collapse = "\n")
sidebar <- gsub("\\$ALTDOC_VIGNETTE_BLOCK", "%s", sidebar)
sidebar <- sprintf(sidebar, tmp)
if (isTRUE(grepl("\\$ALTDOC_VIGNETTE_BLOCK", sidebar))) {
sidebar <- gsub("\\$ALTDOC_VIGNETTE_BLOCK", "%s", sidebar)
sidebar <- sprintf(sidebar, tmp)
}
sidebar <- strsplit(sidebar, "\n")[[1]]
} else {
sidebar <- sidebar[!grepl("\\$ALTDOC_VIGNETTE_BLOCK", sidebar)]
Expand All @@ -81,8 +83,10 @@
tmp <- sprintf("{title: '%s', link: '%s'}", titles, fn_man)
tmp <- paste(tmp, collapse = ", ")
sidebar <- paste(sidebar, collapse = "\n")
sidebar <- gsub("\\$ALTDOC_MAN_BLOCK", "%s", sidebar)
sidebar <- sprintf(sidebar, tmp)
if (isTRUE(grepl("\\$ALTDOC_MAN_BLOCK", sidebar))) {
sidebar <- gsub("\\$ALTDOC_MAN_BLOCK", "%s", sidebar)
sidebar <- sprintf(sidebar, tmp)
}
sidebar <- strsplit(sidebar, "\n")[[1]]
} else {
sidebar <- sidebar[!grepl("\\$ALTDOC_MAN_BLOCK", sidebar)]
Expand Down

0 comments on commit fff94f5

Please sign in to comment.