Skip to content

Commit

Permalink
Set year to 1979 if earlier than 2018, close #239
Browse files Browse the repository at this point in the history
  • Loading branch information
Robinlovelace committed Jul 31, 2024
1 parent 4b9074a commit 360f2b2
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions R/get.R
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,11 @@ get_stats19 = function(year = NULL,
output_format = "tibble"
}

# Update year to 1979 if it's NULL or before 2018:
if (is.null(year) || year < 2018) {
year = 1979
}

# download what the user wanted
dl_stats19(year = year,
type = type,
Expand Down

0 comments on commit 360f2b2

Please sign in to comment.