FEATURE: selectable avatars

This commit is contained in:
Régis Hanol
2018-07-18 12:57:43 +02:00
parent a24b9981c6
commit 6d6e026e3c
28 changed files with 435 additions and 80 deletions

View File

@@ -25,6 +25,16 @@ class SiteController < ApplicationController
render json: custom_emoji
end
def selectable_avatars
avatars = if SiteSetting.selectable_avatars_enabled?
(SiteSetting.selectable_avatars.presence || "").split("\n")
else
[]
end
render json: avatars, root: false
end
def basic_info
results = {
logo_url: UrlHelper.absolute(SiteSetting.logo_url),