Is there a reason that this needs to be protected like this (with the `respond_to?` calls)? I would expect that `request.environment` would always be a valid `Puppet::Node::Environment` instance, and if not, then we should figure out how to fix that.