Merge pull request #10119 from kraktus/date_safari_download

Fix download page date range for Safari
deepcrayonfish^2
Thibault Duplessis 2021-11-17 08:20:57 +01:00 committed by GitHub
commit 505b32ef10
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -9,8 +9,8 @@ function generateSearchParams(): string {
});
['since', 'until'].forEach(name => {
const minTimestamp = 1356998400070;
const date = $(`#dl-date-${name}`).val() as string;
const minTimestamp = 1356998400070; // 01/01/2013, 01:00:00
const date = ($(`#dl-date-${name}`).val() as string).replace(/-/g, '/'); // for Safari https://stackoverflow.com/a/4310986/11955835
const time = $(`#dl-time-${name}`).val() as string;
if (date.length == 10) {
// the 00:00:00 is necessary for the time to be interpreted in the local timezone