mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-03 06:58:42 +00:00
not all use DD/MM/YY, so use locale's date format
This commit is contained in:
parent
819ab070b4
commit
56fb8f6225
1 changed files with 3 additions and 3 deletions
|
@ -319,16 +319,16 @@ def ftime(seconds):
|
||||||
|
|
||||||
def fdate(seconds):
|
def fdate(seconds):
|
||||||
"""
|
"""
|
||||||
Formats a date string in the form of DD/MM/YY based on the systems timezone
|
Formats a date string in the locale's date representation based on the systems timezone
|
||||||
|
|
||||||
:param seconds: float, time in seconds since the Epoch
|
:param seconds: float, time in seconds since the Epoch
|
||||||
:returns: a string in the form of DD/MM/YY or "" if seconds < 0
|
:returns: a string in the locale's date representation or "" if seconds < 0
|
||||||
:rtype: string
|
:rtype: string
|
||||||
|
|
||||||
"""
|
"""
|
||||||
if seconds < 0:
|
if seconds < 0:
|
||||||
return ""
|
return ""
|
||||||
return time.strftime("%d/%m/%y", time.localtime(seconds))
|
return time.strftime("%x", time.localtime(seconds))
|
||||||
|
|
||||||
def is_url(url):
|
def is_url(url):
|
||||||
"""
|
"""
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue