Skip to content

Commit

Permalink
fix deleteRecords based on inveniordm json format
Browse files Browse the repository at this point in the history
  • Loading branch information
eblondel committed May 13, 2024
1 parent 13de804 commit 129e396
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/ZenodoManager.R
Original file line number Diff line number Diff line change
Expand Up @@ -1267,7 +1267,7 @@ ZenodoManager <- R6Class("ZenodoManager",
#' @return \code{TRUE} if all records have been deleted, \code{FALSE} otherwise
deleteRecords = function(q = "", size = 10){
records <- self$getDepositions(q = q, size = size)
records <- records[sapply(records, function(x){!x$submitted})]
records <- records[sapply(records, function(x){x$status == "draft"})]
hasDraftRecords <- length(records)>0
if(length(records)>0){
record_ids <- sapply(records, function(x){x$id})
Expand Down

0 comments on commit 129e396

Please sign in to comment.