Skip to content

Commit 64c9da5

Browse files
committed
style: styler (GHA)
1 parent 71116cb commit 64c9da5

File tree

1 file changed

+11
-10
lines changed

1 file changed

+11
-10
lines changed

R/patch.R

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -245,35 +245,36 @@ tbl_diff2 <- function(earlier_snapshot, later_tbl,
245245
# use faster validation variants:
246246
if (!is_tibble(later_tbl)) {
247247
cli_abort("`later_tbl` must be a tibble",
248-
class = "epiprocess__tbl_diff2__later_tbl_invalid"
249-
)
248+
class = "epiprocess__tbl_diff2__later_tbl_invalid"
249+
)
250250
}
251251
if (is.null(earlier_snapshot)) {
252252
return(later_tbl)
253253
}
254254
if (!is_tibble(earlier_snapshot)) {
255255
cli_abort("`earlier_snapshot` must be a tibble or `NULL`",
256-
class = "epiprocess__tbl_diff2__earlier_tbl_class_invalid"
257-
)
256+
class = "epiprocess__tbl_diff2__earlier_tbl_class_invalid"
257+
)
258258
}
259259
if (!is.character(ukey_names) || !all(ukey_names %in% names(earlier_snapshot))) {
260260
cli_abort("`ukey_names` must be a subset of column names",
261-
class = "epiprocess__tbl_diff2__ukey_names_class_invalid"
262-
)
261+
class = "epiprocess__tbl_diff2__ukey_names_class_invalid"
262+
)
263263
}
264264
later_format <- arg_match0(later_format, c("snapshot", "update"))
265265
if (!(is.vector(compactify_abs_tol, mode = "numeric") &&
266-
length(compactify_abs_tol) == 1L && # nolint:indentation_linter
267-
compactify_abs_tol >= 0)) {
266+
length(compactify_abs_tol) == 1L && # nolint:indentation_linter
267+
compactify_abs_tol >= 0)) {
268268
# Give a specific message:
269269
assert_numeric(compactify_abs_tol, lower = 0, any.missing = FALSE, len = 1L)
270270
# Fallback e.g. for invalid classes not caught by assert_numeric:
271271
cli_abort("`compactify_abs_tol` must be a length-1 double/integer >= 0",
272-
class = "epiprocess__tbl_diff2__compactify_abs_tol_invalid")
272+
class = "epiprocess__tbl_diff2__compactify_abs_tol_invalid"
273+
)
273274
}
274275

275276
all_names <- names(later_tbl)
276-
val_names <- all_names[! (all_names %in% ukey_names)]
277+
val_names <- all_names[!(all_names %in% ukey_names)]
277278
updates <- tbl_fast_anti_join(later_tbl, earlier_snapshot, ukey_names, val_names, compactify_abs_tol)
278279
if (later_format == "snapshot") {
279280
deletions <- tbl_fast_anti_join(earlier_snapshot[ukey_names], later_tbl[ukey_names], ukey_names, character(), 0)

0 commit comments

Comments
 (0)