Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dawoodkhan82 committed Oct 24, 2024
1 parent a55602b commit 2ce3247
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions gradio/chat_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -731,8 +731,15 @@ def _process_example(
def _additional_inputs_in_examples(self):
if self.examples is not None:
for example in self.examples:
if isinstance(example, list) and len(example) > 1:
return True
for idx, example_for_input in enumerate(example):
if example_for_input is not None:
try:
if idx > 0:
return True
else:
continue
except IndexError:
return False
return False

async def _examples_fn(
Expand Down

0 comments on commit 2ce3247

Please sign in to comment.