diff --git a/src/metabase/server/request/util.clj b/src/metabase/server/request/util.clj index 3902e0bb92973498df236925e8c96950baf1c37b..0fef21f8a1d039274ab9fd511f0b1c0c7883fffb 100644 --- a/src/metabase/server/request/util.clj +++ b/src/metabase/server/request/util.clj @@ -37,9 +37,7 @@ (and query-string (re-matches #"^/app/dist/.*\.(js|css)$" uri)) ;; any resource that is named as a cache-busting hex string (e.g. fonts, images) - (re-matches #"^/app/dist/[a-f0-9]{20}+.*$" uri) - ;; GeoJSON proxy requests should also be cached - (re-matches #"^/api/geojson/.*" uri)))) + (re-matches #"^/app/dist/[a-f0-9]{20}+.*$" uri)))) (defn https? "True if the original request made by the frontend client (i.e., browser) was made over HTTPS. diff --git a/test/metabase/api/geojson_test.clj b/test/metabase/api/geojson_test.clj index 648d5681c9fa62e912a1f942e0b48ec25077d0ae..053853932c8ea5ac732f3f48c350f1b5a5ea5516 100644 --- a/test/metabase/api/geojson_test.clj +++ b/test/metabase/api/geojson_test.clj @@ -4,7 +4,6 @@ [metabase.api.geojson :as api.geojson] [metabase.http-client :as client] [metabase.models.setting :as setting] - [metabase.server.middleware.security :as mw.security] [metabase.test :as mt] [metabase.util :as u] [metabase.util.schema :as su] @@ -156,10 +155,6 @@ (is (= {:type "Point" :coordinates [37.77986 -122.429]} (mt/user-http-request :rasta :get 200 "geojson/middle-earth")))) - (testing "response should not include the usual cache-busting headers" - (is (= (#'mw.security/cache-far-future-headers) - (select-keys (:headers (client/client-full-response :get 200 "geojson/middle-earth")) - (keys (#'mw.security/cache-prevention-headers)))))) (testing "should be able to fetch the GeoJSON even if you aren't logged in" (is (= {:type "Point" :coordinates [37.77986 -122.429]}