Skip to content

Commit

Permalink
avoid testing same dateformat twice #1243
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentvanhees committed Jan 4, 2025
1 parent b234e12 commit b09d35b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/g.loadlog.R
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ g.loadlog = function(loglocation = c(), coln1 = c(), colid = c(),
"%y/%m/%d", "%d/%m/%y", "%m/%d/%y", "%y/%d/%m")
if (dateformat_found == TRUE && dateformats_to_consider[1] != dateformat_correct) {
# If found then first try that before trying anything else
dateformats_to_consider = c(dateformat_correct, dateformats_to_consider)
dateformats_to_consider = unique(c(dateformat_correct, dateformats_to_consider))
}
# Detect data format in sleeplog:
for (dateformat in dateformats_to_consider) {
Expand Down

0 comments on commit b09d35b

Please sign in to comment.