Skip to content

Commit

Permalink
fix archive()
Browse files Browse the repository at this point in the history
  • Loading branch information
shikokuchuo committed Jan 24, 2024
1 parent a2a9b58 commit 796f5b0
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions R/archive.R
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,10 @@ archive <- function(..., object, file) {
readArchive(file = ..1)

} else if (dlen == 3L) {
if (dots[[2L]] == "") {
dots[[3L]] == "" && {
d <- dots[[2L]]
if (missing(d)) {
d <- dots[[3L]]
missing(d) && {
interactive() ||
stop("Empty arguments for both 'object' and 'file' passed to archive()\nFor read operations specify 'file' only, write operations both 'object' and 'file'", call. = FALSE)
return(.deconstruct(...))
Expand Down

0 comments on commit 796f5b0

Please sign in to comment.