leave send_message if there are any empty data fields
Dieser Commit ist enthalten in:
Ursprung
f5fc69a908
Commit
979e896d6b
1 geänderte Dateien mit 10 neuen und 0 gelöschten Zeilen
|
@ -423,6 +423,16 @@ class CustomWizard::Builder
|
|||
|
||||
def send_message(user, action, data)
|
||||
|
||||
empty_data = false
|
||||
|
||||
data.each do |k, v|
|
||||
if v.empty?
|
||||
empty_data = true
|
||||
end
|
||||
end
|
||||
# leave if there are any empty fields
|
||||
return if empty_data
|
||||
|
||||
unless action['custom_title_enabled']
|
||||
title = data[action['title']]
|
||||
else
|
||||
|
|
Laden …
In neuem Issue referenzieren