JUNGU commited on
Commit
aeefab9
·
1 Parent(s): 5ea1f97

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -132,8 +132,9 @@ with chat_placeholder:
132
  </div>
133
  """
134
  st.markdown(div, unsafe_allow_html=True)
135
-
136
  last_chat = st.session_state.history[-1]
 
137
  div_start = f"""
138
  <div class="chat-row
139
  {'' if last_chat.origin == 'ai' else 'row-reverse'}">
 
132
  </div>
133
  """
134
  st.markdown(div, unsafe_allow_html=True)
135
+ if st.session_state.history:
136
  last_chat = st.session_state.history[-1]
137
+
138
  div_start = f"""
139
  <div class="chat-row
140
  {'' if last_chat.origin == 'ai' else 'row-reverse'}">