File tree Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -160,9 +160,11 @@ func (h *Host) Connect(term *sshd.Terminal) {
160160 }
161161
162162 // Successfully joined.
163- term .SetPrompt (GetPrompt (user ))
164- term .AutoCompleteCallback = h .AutoCompleteFunction (user )
165- user .SetHighlight (user .Name ())
163+ if ! apiMode {
164+ term .SetPrompt (GetPrompt (user ))
165+ term .AutoCompleteCallback = h .AutoCompleteFunction (user )
166+ user .SetHighlight (user .Name ())
167+ }
166168
167169 // Should the user be op'd on join?
168170 if h .isOp (term .Conn ) {
@@ -210,6 +212,11 @@ func (h *Host) Connect(term *sshd.Terminal) {
210212 // FIXME: Any reason to use h.room.Send(m) instead?
211213 h .HandleMsg (m )
212214
215+ if apiMode {
216+ // Skip the remaining rendering workarounds
217+ continue
218+ }
219+
213220 cmd := m .Command ()
214221 if cmd == "/nick" || cmd == "/theme" {
215222 // Hijack /nick command to update terminal synchronously. Wouldn't
You can’t perform that action at this time.
0 commit comments