mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-12-19 20:12:46 -05:00
4db87e4972
tried to keep as much logic/data from the original source code
23 lines
585 B
Ruby
23 lines
585 B
Ruby
require 'discourse_plugin'
|
|
|
|
# /!\ WARNING /!\
|
|
# This plugin has been extracted from the Discourse source code and has not been tested.
|
|
# It really needs some love <3
|
|
# /!\ WARNING /!\
|
|
|
|
module DiscourseImgur
|
|
|
|
class Plugin < DiscoursePlugin
|
|
|
|
def setup
|
|
# add_setting(:enable_imgur, false)
|
|
# add_setting(:imgur_client_id, '')
|
|
# add_setting(:imgur_endpoint, "https://api.imgur.com/3/image.json")
|
|
|
|
# TODO: Mix the following logic in Upload#store_file
|
|
# return Imgur.store_file(file, image_info, upload_id) if SiteSetting.enable_imgur?
|
|
end
|
|
|
|
end
|
|
|
|
end
|