Skip to content

Commit fc6ad1a

Browse files
authored
Merge pull request #301 from frictionlessdata/returns
Use correct roxygen tag `@returns` and Roxygen 8.0.0
2 parents 6807f46 + 8ee22c9 commit fc6ad1a

33 files changed

Lines changed: 56 additions & 55 deletions

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,4 +58,4 @@ Config/testthat/edition: 3
5858
Encoding: UTF-8
5959
LazyData: true
6060
Roxygen: list(markdown = TRUE)
61-
RoxygenNote: 7.3.3
61+
Config/roxygen2/version: 8.0.0

R/add_resource.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
#' The following properties are automatically set and can't be provided with
3838
#' `...`: `name`, `data`, `path`, `schema`, `profile`, `format`, `mediatype`,
3939
#' `encoding` and `dialect`.
40-
#' @return `package` with one additional resource.
40+
#' @returns `package` with one additional resource.
4141
#' @family edit functions
4242
#' @export
4343
#' @examples

R/check_data.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#' Check if an object is a non-empty data frame.
44
#'
55
#' @param data A data frame.
6-
#' @return `data` invisibly or an error.
6+
#' @returns `data` invisibly or an error.
77
#' @family check functions
88
#' @noRd
99
check_data <- function(data) {

R/check_package.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#' Check if an object is a Data Package object with the required properties.
44
#'
55
#' @inheritParams read_resource
6-
#' @return `package` invisibly or an error.
6+
#' @returns `package` invisibly or an error.
77
#' @family check functions
88
#' @export
99
#' @examples

R/check_path.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#' @param directory Directory to prepend to path.
1111
#' @param safe Require `path` to be safe, i.e. no absolute or relative parent
1212
#' paths.
13-
#' @return Absolute path or URL or an error.
13+
#' @returns Absolute path or URL or an error.
1414
#' @family check functions
1515
#' @noRd
1616
check_path <- function(path, directory = NULL, safe = FALSE) {

R/check_schema.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
#'
66
#' @param schema List describing a Table Schema.
77
#' @param data A data frame against which the Table Schema must be compared.
8-
#' @return `schema` invisibly or an error.
8+
#' @returns `schema` invisibly or an error.
99
#' @family check functions
1010
#' @noRd
1111
check_schema <- function(schema, data = NULL) {

R/col_types.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#' Creates a [readr::cols()] for all fields in a Table Schema.
44
#'
55
#' @inheritParams check_schema
6-
#' @return A [readr::cols()] object.
6+
#' @returns A [readr::cols()] object.
77
#' @family parse functions
88
#' @noRd
99
cols <- function(schema) {
@@ -33,7 +33,7 @@ cols <- function(schema) {
3333
#' Creates a column specification for a specific field in a Table Schema.
3434
#'
3535
#' @param field Field in a Table schema.
36-
#' @return A readr collector.
36+
#' @returns A readr collector.
3737
#' @family parse functions
3838
#' @noRd
3939
field_to_col <- function(field) {

R/collectors.R

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#' Parse a string field
22
#'
33
#' @inheritParams col_number
4-
#' @return A readr collector.
4+
#' @returns A readr collector.
55
#' @family parse functions
66
#' @noRd
77
col_string <- function(enum) {
@@ -17,7 +17,7 @@ col_string <- function(enum) {
1717
#' @param enum A field's `constraints.enum`.
1818
#' @param group_char A field's `groupChar`.
1919
#' @param bare_number A field's `bareNumber`.
20-
#' @return A readr collector.
20+
#' @returns A readr collector.
2121
#' @family parse functions
2222
#' @noRd
2323
col_number <- function(enum, group_char, bare_number) {
@@ -35,7 +35,7 @@ col_number <- function(enum, group_char, bare_number) {
3535
#' Parse an integer field
3636
#'
3737
#' @inheritParams col_number
38-
#' @return A readr collector.
38+
#' @returns A readr collector.
3939
#' @family parse functions
4040
#' @noRd
4141
col_integer <- function(enum, bare_number) {
@@ -51,7 +51,7 @@ col_integer <- function(enum, bare_number) {
5151
#' Parse a date field
5252
#'
5353
#' @inheritParams col_datetime
54-
#' @return A readr collector.
54+
#' @returns A readr collector.
5555
#' @family parse functions
5656
#' @noRd
5757
col_date <- function(format) {
@@ -69,7 +69,7 @@ col_date <- function(format) {
6969
#' Parse a time field
7070
#'
7171
#' @inheritParams col_datetime
72-
#' @return A readr collector.
72+
#' @returns A readr collector.
7373
#' @family parse functions
7474
#' @noRd
7575
col_time <- function(format) {
@@ -87,7 +87,7 @@ col_time <- function(format) {
8787
#' Parse a datetime field
8888
#'
8989
#' @param format A field's `format`.
90-
#' @return A readr collector.
90+
#' @returns A readr collector.
9191
#' @family parse functions
9292
#' @noRd
9393
col_datetime <- function(format) {

R/create_package.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#'
1818
#' @param descriptor List to be made into a Data Package object.
1919
#' If undefined, an empty Data Package will be created from scratch.
20-
#' @return A Data Package object.
20+
#' @returns A Data Package object.
2121
#' @family create functions
2222
#' @export
2323
#' @examples

R/create_schema.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#' Data Package standard.
88
#'
99
#' @param data A data frame.
10-
#' @return List describing a Table Schema.
10+
#' @returns List describing a Table Schema.
1111
#' @family create functions
1212
#' @export
1313
#' @examples

0 commit comments

Comments
 (0)