Skip to content

Commit

Permalink
More ruby-esk way to do the comparison
Browse files Browse the repository at this point in the history
  • Loading branch information
computermacgyver committed Aug 28, 2024
1 parent e7822e0 commit 3535e95
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/bot/smooch.rb
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@ def self.is_a_shortcut_for_submission?(state, message)
self.is_v2? && (state == 'main' || state == 'waiting_for_message') && (
!message['mediaUrl'].blank? ||
::Bot::Alegre.get_number_of_words(message['text'].to_s) > CheckConfig.get('min_number_of_words_for_tipline_submit_shortcut', 10, :integer) ||
URI.regexp.match(message['text'].to_s)!=nil # URL in message?
!URI.regexp.match(message['text'].to_s).nil? # URL in message?
)
end

Expand Down

0 comments on commit 3535e95

Please sign in to comment.