mattb512 commited on
Commit
67c0304
1 Parent(s): 34a5288

add validation

Browse files
Files changed (1) hide show
  1. serve/gradio_web_server.py +1 -1
serve/gradio_web_server.py CHANGED
@@ -117,7 +117,7 @@ def add_text(state, text, image, image_process_mode, request: gr.Request):
117
  print(text, image)
118
  if not text or not image:
119
  print("text empty")
120
- raise gr.Warning("Please provide both a prompt and an image.")
121
 
122
  if len(text) <= 0 and image is None:
123
  state.skip_next = True
 
117
  print(text, image)
118
  if not text or not image:
119
  print("text empty")
120
+ raise gr.Warning("Please provide a prompt and an image.")
121
 
122
  if len(text) <= 0 and image is None:
123
  state.skip_next = True