Class: Preflight::Rules::InfoSpecifiesTrapping
- Inherits:
-
Object
- Object
- Preflight::Rules::InfoSpecifiesTrapping
- Defined in:
- lib/preflight/rules/info_specifies_trapping.rb
Overview
Instance Method Summary collapse
Instance Method Details
#check_hash(ohash) ⇒ Object
20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/preflight/rules/info_specifies_trapping.rb', line 20 def check_hash(ohash) info = ohash.object(ohash.trailer[:Info]) if !info.has_key?(:Trapped) [ Issue.new("Info dict does not specify Trapped", self) ] elsif info[:Trapped] != :True && info[:Trapped] != :False [ Issue.new("Trapped value of Info dict must be True or False", self) ] else [] end end |