better handling intrument export

This commit is contained in:
Andreas Gammelgaard Damsbo 2024-11-20 12:09:30 +01:00
parent c3b54b0860
commit b7e0873b00
No known key found for this signature in database

View File

@ -48,7 +48,7 @@ export_redcap_instrument <- function(data,
ideas on exporting multiple instruments.")
}
if (record.id %in% data[["field_name"]]){
if (!is.na(record.id) && record.id %in% data[["field_name"]]){
data <- data[-match(record.id,data[["field_name"]]),]
}