mirror of
https://github.com/f-droid/fdroidserver.git
synced 2026-05-18 21:47:19 -04:00
Fix added type
The added time should be a datetime, not a time.struct_time.
Regression of 290b9050
Closes: #1012
This commit is contained in:
committed by
Michael Pöhn
parent
6394ededa1
commit
8f24cae3be
@@ -34,7 +34,7 @@ import json
|
||||
import time
|
||||
import yaml
|
||||
import copy
|
||||
from datetime import datetime
|
||||
from datetime import datetime, timezone
|
||||
from argparse import ArgumentParser
|
||||
from pathlib import Path
|
||||
|
||||
@@ -1167,7 +1167,7 @@ def scan_repo_files(apkcache, repodir, knownapks, use_date_from_file=False):
|
||||
|
||||
if use_date_from_file:
|
||||
timestamp = stat.st_ctime
|
||||
default_date_param = time.gmtime(time.mktime(datetime.fromtimestamp(timestamp).timetuple()))
|
||||
default_date_param = datetime.fromtimestamp(timestamp, tz=timezone.utc)
|
||||
else:
|
||||
default_date_param = None
|
||||
|
||||
|
||||
Reference in New Issue
Block a user