Skip to content

Commit

Permalink
#137 publication_date
Browse files Browse the repository at this point in the history
  • Loading branch information
eblondel committed Mar 18, 2024
1 parent c3ac84e commit 5ce0cfb
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
10 changes: 4 additions & 6 deletions R/ZenodoRecord.R
Original file line number Diff line number Diff line change
Expand Up @@ -284,13 +284,11 @@ ZenodoRecord <- R6Class("ZenodoRecord",
self$metadata$publisher = publisher
},

#' @description Set the publication date.
#' @param publicationDate object of class \code{Date}
#' @description Set the publication date. For more information on the accepted format,
#' please check https://inveniordm.docs.cern.ch/reference/metadata/#publication-date-1
#' @param publicationDate object of class \code{character}
setPublicationDate = function(publicationDate){
if(!is(publicationDate,"Date")){
stop("The publication date should be a 'Date' object")
}
self$metadata$publication_date <- as(publicationDate, "character")
self$metadata$publication_date <- publicationDate
},

#' @description Set the embargo date.
Expand Down
5 changes: 3 additions & 2 deletions man/ZenodoRecord.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 5ce0cfb

Please sign in to comment.