Software / code / prosody
Comparison
plugins/mod_admin_shell.lua @ 13596:85e8cc6870ae
mod_admin_shell: Mark event as handled when requested input is submitted
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Tue, 07 Jan 2025 19:23:23 +0000 |
| parent | 13594:abbdcef552fb |
| child | 13597:62aca6adcfd3 |
comparison
equal
deleted
inserted
replaced
| 13595:6fafe51df188 | 13596:85e8cc6870ae |
|---|---|
| 209 if not input_promise then | 209 if not input_promise then |
| 210 event.origin.send(st.stanza("repl-result", { type = "error" }):text("Internal error - unexpected input")); | 210 event.origin.send(st.stanza("repl-result", { type = "error" }):text("Internal error - unexpected input")); |
| 211 return true; | 211 return true; |
| 212 end | 212 end |
| 213 input_promise.resolve(event.stanza:get_text()); | 213 input_promise.resolve(event.stanza:get_text()); |
| 214 return true; | |
| 214 end); | 215 end); |
| 215 | 216 |
| 216 function console:new_session(admin_session) | 217 function console:new_session(admin_session) |
| 217 local session = { | 218 local session = { |
| 218 send = function (t) | 219 send = function (t) |