lib/elasticsearch/api/actions/indices/delete_template.rb in elasticsearch-api-1.0.11 vs lib/elasticsearch/api/actions/indices/delete_template.rb in elasticsearch-api-1.0.12

- old
+ new

@@ -26,10 +26,12 @@ path = Utils.__pathify '_template', Utils.__escape(arguments[:name]) params = Utils.__validate_and_extract_params arguments, valid_params body = nil - Utils.__rescue_from_not_found do + if Array(arguments[:ignore]).include?(404) + Utils.__rescue_from_not_found { perform_request(method, path, params, body).body } + else perform_request(method, path, params, body).body end end end end