mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-10-01 00:30:13 +02: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:
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
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user