merve HF staff commited on
Commit
89c8fdb
·
1 Parent(s): 3252678

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -1
app.py CHANGED
@@ -30,7 +30,11 @@ input = st.text_input("Ask me 🤗")
30
  message_history.append(input)
31
 
32
  with placeholder.container():
33
- message(message_history[-1]) # display the latest message
 
 
 
 
34
 
35
  message(input, is_user=True) # align's the message to the right
36
 
 
30
  message_history.append(input)
31
 
32
  with placeholder.container():
33
+ if message_history[-1] != "":
34
+ message(message_history[-1]) # display the latest message
35
+ else:
36
+ message(message_history[-2])
37
+
38
 
39
  message(input, is_user=True) # align's the message to the right
40