diff --git a/lib/admin_command.rb b/lib/admin_command.rb index f1e115599dec04004a66c2584be812cd723687c9..f01c4bfed49451c62d1c5a1ccab074f3b0c947f2 100644 --- a/lib/admin_command.rb +++ b/lib/admin_command.rb @@ -87,7 +87,7 @@ class AdminCommand reg = @target_customer.registered? vars = { notice: notice, customer_id: @target_customer.customer_id, - jid: @target_customer.jid, tel: reg&.phone } + jid: @target_customer.jid, tel: reg ? reg.phone : nil } reply(FormTemplate.render("admin_menu", **vars)).then do |response| if response.form.field("action") handle(response.form.field("action").value, response.action)