From 9d48fb85437e64efa0d1dfe64a363735953f4748 Mon Sep 17 00:00:00 2001
From: Alex Reisner <alex@alexreisner.com>
Date: Wed, 30 Nov 2016 16:45:48 -0500
Subject: [PATCH] Avoid calling fetch_data within method.

---
 lib/geocoder/lookups/ban_data_gouv_fr.rb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/geocoder/lookups/ban_data_gouv_fr.rb b/lib/geocoder/lookups/ban_data_gouv_fr.rb
index 1aad701f..0c577f05 100644
--- a/lib/geocoder/lookups/ban_data_gouv_fr.rb
+++ b/lib/geocoder/lookups/ban_data_gouv_fr.rb
@@ -21,8 +21,8 @@ module Geocoder::Lookup
 
     private # ---------------------------------------------------------------
 
-    def any_result?(query)
-      fetch_data(query)['features'].any?
+    def any_result?(doc)
+      doc['features'].any?
     end
 
     def results(query)
-- 
GitLab