Add type coercion to fix #2054

This commit is contained in:
Ryan Lue 2018-06-06 23:55:23 +08:00
parent 0693420fa1
commit 2233cded7f

View file

@ -61,7 +61,7 @@ end
if connection.execute("SHOW tables LIKE 'settings';").any? && if connection.execute("SHOW tables LIKE 'settings';").any? &&
Setting.get('postmaster_max_size').present? && Setting.get('postmaster_max_size').present? &&
Setting.get('postmaster_max_size') > max_allowed_packet_mb Setting.get('postmaster_max_size').to_i > max_allowed_packet_mb
printf "\e[33m" # ANSI yellow printf "\e[33m" # ANSI yellow
puts <<~MSG puts <<~MSG
Warning: Database config value 'max_allowed_packet' less than Zammad setting 'Maximum Email Size' Warning: Database config value 'max_allowed_packet' less than Zammad setting 'Maximum Email Size'