~singpolyma/sgx-jmp

0051c8e75071943686cca124c2f0701c3bb4a557 — Christopher Vollick 10 months ago e5759b3
Handle Empty Admin Menu Response

Some automated processes don't care for our menu, and rather than
crashing it should just consider our process to be done.
1 files changed, 3 insertions(+), 1 deletions(-)

M lib/admin_command.rb
M lib/admin_command.rb => lib/admin_command.rb +3 -1
@@ 22,7 22,9 @@ class AdminCommand

	def menu
		reply(FormTemplate.render("admin_menu")).then do |response|
			handle(response.form.field("action").value)
			if response.form.field("action")
				handle(response.form.field("action").value)
			end
		end
	end