Skip to content

Commit

Permalink
Move error checking
Browse files Browse the repository at this point in the history
  • Loading branch information
mattkerlogue committed Dec 24, 2024
1 parent 8fe225e commit 4c5ee9d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions narrowbot.R
Original file line number Diff line number Diff line change
Expand Up @@ -223,11 +223,11 @@ if (Sys.getenv("NARROWBOT_TEST") == "true") {
message("Test mode, will not log")
} else {
readr::write_lines(log_text, "narrowbotr.log", append = TRUE)
if (is.character(toot_out) || is.character(bsky_out)) {
stop("Error with either Mastodon or Bsky but not both")
}
}

# show log output for GH actions log
cat(log_text)

if (is.character(toot_out) || is.character(bsky_out)) {
stop("Error with either Mastodon or Bsky but not both")
}

0 comments on commit 4c5ee9d

Please sign in to comment.