aboutsummaryrefslogtreecommitdiff
path: root/modules/images.py
diff options
context:
space:
mode:
authorw-e-w <40751091+w-e-w@users.noreply.github.com>2022-10-25 23:39:21 +0900
committerAUTOMATIC1111 <16777216c@gmail.com>2022-10-26 09:51:32 +0300
commit757264c453eca533ee1c9ea7e9d9b45a009367d7 (patch)
tree92b632029f37dc97ee478eafb1c0834f9553a5ee /modules/images.py
parent146856f66d7e06a762f5ef5bf61a226057de6757 (diff)
default_time_format if format is blank
Diffstat (limited to 'modules/images.py')
-rw-r--r--modules/images.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/images.py b/modules/images.py
index ed448a8a..bfc2ba06 100644
--- a/modules/images.py
+++ b/modules/images.py
@@ -343,7 +343,7 @@ class FilenameGenerator:
def datetime(self, *args):
time_datetime = datetime.datetime.now()
- time_format = args[0] if len(args) > 0 else self.default_time_format
+ time_format = args[0] if len(args) > 0 and args[0] != "" else self.default_time_format
try:
time_zone = pytz.timezone(args[1]) if len(args) > 1 else None
except pytz.exceptions.UnknownTimeZoneError as _: