Skip to content

Commit

Permalink
fix: export S3 methods
Browse files Browse the repository at this point in the history
this fixes roxygen2 warnings and is the right thing to do, cf.:

- https://roxygen2.r-lib.org/articles/namespace.html#s3
- r-lib/roxygen2#1322
  • Loading branch information
salim-b committed Sep 4, 2024
1 parent 44ba0c0 commit 5d6c288
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ S3method(print,api_grid_local)
S3method(print,api_plot)
S3method(print,kaleidoScope)
S3method(print,plotly_data)
S3method(process,api_image)
S3method(process,api_plot)
S3method(process,default)
S3method(to_basic,GeomAbline)
S3method(to_basic,GeomAlluvium)
S3method(to_basic,GeomAnnotationMap)
Expand Down
3 changes: 3 additions & 0 deletions R/process.R
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,17 @@ process <- function(resp) {
UseMethod("process")
}

#' @export
process.default <- function(resp) {
json_content(relay_error(resp))
}

#' @export
process.api_plot <- function(resp) {
json_content(relay_error(resp))
}

#' @export
process.api_image <- function(resp) {
relay_error(resp)
type <- resp[["headers"]][["content-type"]]
Expand Down

0 comments on commit 5d6c288

Please sign in to comment.