Skip to content

Commit

Permalink
check for empty string
Browse files Browse the repository at this point in the history
  • Loading branch information
kbvernon committed Sep 18, 2024
1 parent c698bf3 commit aeba4b7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion R/use_crate.R
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@ use_crate <- function(
)

# clear empty options
cargo_add_opts <- purrr::discard(cargo_add_opts, rlang::is_empty)
is_null_or_empty_string <- function(x){ !nzchar(x) || rlang::is_empty(x) }

Check warning on line 67 in R/use_crate.R

View workflow job for this annotation

GitHub Actions / lint

file=R/use_crate.R,line=67,col=41,[brace_linter] Opening curly braces should never go on their own line and should always be followed by a new line.

Check warning on line 67 in R/use_crate.R

View workflow job for this annotation

GitHub Actions / lint

file=R/use_crate.R,line=67,col=41,[brace_linter] There should be a space before an opening curly brace.

Check warning on line 67 in R/use_crate.R

View workflow job for this annotation

GitHub Actions / lint

file=R/use_crate.R,line=67,col=41,[paren_body_linter] There should be a space between a right parenthesis and a body expression.

Check warning on line 67 in R/use_crate.R

View workflow job for this annotation

GitHub Actions / lint

file=R/use_crate.R,line=67,col=76,[brace_linter] Closing curly-braces should always be on their own line, unless they are followed by an else.
cargo_add_opts <- purrr::discard(cargo_add_opts, is_null_or_empty_string)

# combine option names and values into single strings
adtl_args <- unname(purrr::imap_chr(
Expand Down

0 comments on commit aeba4b7

Please sign in to comment.