lib/lita/handlers/locker_misc.rb in lita-locker-1.0.8 vs lib/lita/handlers/locker_misc.rb in lita-locker-1.0.9

- old
+ new

@@ -77,10 +77,10 @@ def list(response) username = response.match_data['username'] user = Lita::User.fuzzy_find(username) return response.reply(t('user.unknown', user: username)) unless user l = user_locks(user) - return response.reply(t('user.no_active_locks', user: user.name)) unless l.size > 0 + return response.reply(t('user.no_active_locks', user: user.name)) if l.empty? composed = '' l.each do |label_name| composed += "Label: #{label_name}\n" end response.reply(composed)