Removed ImageProxyController API route

• Removed:
- ImageProxyController API route
- removed from news reducer for trends.

• Todo:
- Devise solution for integrating cross site images from trends -> social
This commit is contained in:
Developer
2021-02-18 13:34:08 -05:00
parent 559ccc7e51
commit 65949c7e71
3 changed files with 1 additions and 16 deletions

View File

@@ -1,14 +0,0 @@
require 'base64'
require 'net/http'
class Api::V2::ImageProxyController < EmptyController
def get
if params[:trends_url].nil?
raise GabSocial::NotPermittedError
else
url = URI.parse(params[:trends_url])
image = Net::HTTP.get_response(url)
send_data image.body, type: image.content_type, disposition: 'inline'
end
end
end