Skip to content

Commit

Permalink
Increase resilience if lookup var comes back with nil object
Browse files Browse the repository at this point in the history
  • Loading branch information
Travis Fields committed Jun 24, 2014
1 parent 0427248 commit 64f0ae2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/puppet/parser/functions/has_interface_with.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ module Puppet::Parser::Functions
interfaces = lookupvar('interfaces')

# If we do not have any interfaces, then there are no requested attributes
return false if (interfaces == :undefined)
return false if (interfaces == :undefined || interfaces.nil?)

interfaces = interfaces.split(',')

Expand Down

0 comments on commit 64f0ae2

Please sign in to comment.