euroexchange: Fix removed APISite.getcurrenttime()

Pywikibot removed method  APISite.getcurrenttime replaced with
APISite.server_time
This commit is contained in:
2021-03-06 17:35:02 +01:00
parent 59aaac408d
commit eed989fd2a

View File

@@ -276,7 +276,7 @@ class EuroExchangeBot( pywikibot.bot.BaseBot ):
last_update = self.current_job.filepage.latest_file_info.timestamp
# Get current time
now = pywikibot.Site().getcurrenttime()
now = pywikibot.Site().server_time()
# Calculate allowed delta (with tolerance)
delta = datetime.timedelta( days=self.current_job.freq, hours=-2 )