lib/hieracles/puppetdb/request.rb in hieracles-0.3.4 vs lib/hieracles/puppetdb/request.rb in hieracles-0.3.5
- old
+ new
@@ -54,9 +54,13 @@
query = Query.new args
make_hashed @client.request("resources", query.elements)
end
alias_method :res, :resources
+ def events
+ @client.request("events")
+ end
+
private
def extract_names(resp, label = 'certname')
resp.data = resp.data.reduce([]) do |a, d|
a << d[label]