Merge pull request #206 from mmozuras/refactor_unless_blanks_into_presents

Refactor unless blanks into presents
This commit is contained in:
Reinier Balt 2013-09-13 06:08:16 -07:00
commit e2eb31cfcc
15 changed files with 25 additions and 25 deletions

View file

@ -102,14 +102,14 @@ module Todos
end
def project_specified_by_name?
return false unless @attributes['project_id'].blank?
return false if @attributes['project_id'].present?
return false if project_name.blank?
return false if project_name == 'None'
true
end
def context_specified_by_name?
return false unless @attributes['context_id'].blank?
return false if @attributes['context_id'].present?
return false if context_name.blank?
true
end