@Rub21 commented on this pull request.


> @@ -36,6 +36,21 @@ def show
 
     private
 
+    # The file is stored gzipped on S3. If the client supports gzip, we send it
+    # as-is and the client unzips it, which saves server CPU and bandwidth.
+    # If the client does not support gzip, the server unzips it before sending.
+    def send_gpx(trace)
+      accepts_gzip = request.accept_encoding.to_s.split(",").any? { |encoding| 
encoding.split(";").first.strip == "gzip" }

I looked at the docs. It would work, but switching the gem would touch more 
files across the app, and adding a more generic library just for one line of 
code does noe feel worth it. I think keeping small is fine for now. 


-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/7124#discussion_r3365873148
You are receiving this because you are subscribed to this thread.

Message ID: 
<openstreetmap/openstreetmap-website/pull/7124/review/[email protected]>
_______________________________________________
rails-dev mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/rails-dev

Reply via email to