Docfile commited on
Commit
3ea5812
·
verified ·
1 Parent(s): f8ae468

Update templates/index.html

Browse files
Files changed (1) hide show
  1. templates/index.html +5 -1
templates/index.html CHANGED
@@ -180,8 +180,12 @@
180
  const formData = new FormData();
181
  formData.append('image', file);
182
 
183
- const eventSource = new EventSource('/generate?' + new URLSearchParams(formData));
184
 
 
 
 
 
 
185
  let completeResponse = '';
186
 
187
  eventSource.onmessage = function (event) {
 
180
  const formData = new FormData();
181
  formData.append('image', file);
182
 
 
183
 
184
+ const eventSource = new EventSource('/generate', {
185
+ method: 'POST',
186
+ body: formData
187
+ });
188
+
189
  let completeResponse = '';
190
 
191
  eventSource.onmessage = function (event) {