def protected?
      @protected ||= self.class.protected_resources.any? do |thing|
                       if thing.is_a?(Proc)
                         thing.call(self)
                       else
                         id == thing
                       end
                     end
    end
def protected?
      @protected ||= self.class.protected_resources.any? do |thing|
                       if thing.is_a?(Proc)
                         thing.call(self)
                       else
                         id == thing
                       end
                     end
    end
Determine if this current resource is protected. Resources may be
 protected by name or by a Proc. A protected resource is one that should
 not be modified (i.e. created/updated/deleted) by the user. An example of
 a protected resource is the pivotal key or the chef-webui client.

 @return [Boolean]