diff options
| author | Matt Mayer <[email protected]> | 2024-03-28 19:02:38 +0700 |
|---|---|---|
| committer | GitHub <[email protected]> | 2024-03-28 13:02:38 +0100 |
| commit | da35c51d16eccd99a7001a5b055a24806168435d (patch) | |
| tree | 611aeaf1e12f27e5de60ba46864896c2e311374b /docs/guide | |
| parent | 47f008aff5aee08057ad5445d5b3dfbd1b196934 (diff) | |
| download | faker-da35c51d16eccd99a7001a5b055a24806168435d.tar.xz faker-da35c51d16eccd99a7001a5b055a24806168435d.zip | |
refactor(date)!: stricter error handling of between (#2719)
Diffstat (limited to 'docs/guide')
| -rw-r--r-- | docs/guide/upgrading_v9/2711.md | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/docs/guide/upgrading_v9/2711.md b/docs/guide/upgrading_v9/2711.md new file mode 100644 index 00000000..ef9757d3 --- /dev/null +++ b/docs/guide/upgrading_v9/2711.md @@ -0,0 +1,3 @@ +### Require `from` and `to` in `faker.date.between()` and `betweens()` + +Previously, in `faker.date.between()` and `faker.date.betweens()` if the `from` or `to` parameter was omitted (in Javascript) or an invalid date (in Javascript or Typescript), they would default to the current date or reference date. Now, both boundaries must now be given explictly. If you still need the old behavior, you can pass `Date.now()` or the reference date for `from` or `to`. |
