Skip to content

Commit 242163b

Browse files
committed
address #14
1 parent 09e7f95 commit 242163b

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

R/parse_hidden.r

+3
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,9 @@ parse_video <- function(json_string, video_id) {
114114

115115
#' @noRd
116116
parse_search <- function(res) {
117+
if (length(purrr::pluck(res, "body")) == 0L)
118+
cli::cli_abort("Unfortunalty, the search endpoint has changed and returns empty results. See {.url https://github.com/JBGruber/traktok/issues/14}.")
119+
117120
tt_data <- res |>
118121
httr2::resp_body_json()
119122

0 commit comments

Comments
 (0)