1
0
mirror of https://github.com/moparisthebest/SickRage synced 2024-12-13 19:42:20 -05:00

Use day numbers instead of text for language independent day name fuzzyness.

This commit is contained in:
JackDandy 2014-06-07 02:39:17 +01:00
parent 08159e2872
commit 02ecb18eff

View File

@ -113,10 +113,10 @@
result = (0 == week ? airdatetime.calendar() : '');
if (/\bOn\b/i.test(result)) {
var fuzzer = false, weekday = today.format('dd');
if (/we/i.test(weekday))
var fuzzer = false, weekday = today.day();
if (3 == weekday)
fuzzer = (5 <= day);
else if (/(?:th|fr)/i.test(weekday))
else if (4 == weekday || 5 == weekday)
fuzzer = (4 <= day);
else
fuzzer = (6 == day);