summaryrefslogtreecommitdiffstats
path: root/g4f/gui/server/backend.py
diff options
context:
space:
mode:
authorHeiner Lohaus <hlohaus@users.noreply.github.com>2024-01-23 01:47:55 +0100
committerHeiner Lohaus <hlohaus@users.noreply.github.com>2024-01-23 01:47:55 +0100
commit07c944ad0a90e10e9401d34a626bbc7878ffab2a (patch)
tree05207374083d6e751cd84107259f5bd1e4d1e971 /g4f/gui/server/backend.py
parentImprove CreateImagesBing (diff)
downloadgpt4free-07c944ad0a90e10e9401d34a626bbc7878ffab2a.tar
gpt4free-07c944ad0a90e10e9401d34a626bbc7878ffab2a.tar.gz
gpt4free-07c944ad0a90e10e9401d34a626bbc7878ffab2a.tar.bz2
gpt4free-07c944ad0a90e10e9401d34a626bbc7878ffab2a.tar.lz
gpt4free-07c944ad0a90e10e9401d34a626bbc7878ffab2a.tar.xz
gpt4free-07c944ad0a90e10e9401d34a626bbc7878ffab2a.tar.zst
gpt4free-07c944ad0a90e10e9401d34a626bbc7878ffab2a.zip
Diffstat (limited to 'g4f/gui/server/backend.py')
-rw-r--r--g4f/gui/server/backend.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/g4f/gui/server/backend.py b/g4f/gui/server/backend.py
index d5c59ed1..9346f489 100644
--- a/g4f/gui/server/backend.py
+++ b/g4f/gui/server/backend.py
@@ -137,7 +137,7 @@ class Backend_Api:
if 'image' in request.files:
file = request.files['image']
if file.filename != '' and is_allowed_extension(file.filename):
- kwargs['image'] = to_image(file.stream)
+ kwargs['image'] = to_image(file.stream, file.filename.endswith('.svg'))
if 'json' in request.form:
json_data = json.loads(request.form['json'])
else: