Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Pleroma
pleroma
Commits
0f194dc5
Commit
0f194dc5
authored
Jan 31, 2018
by
eal
Browse files
Merge branch 'feature/instance-thumbnail-api' into 'develop'
Provide instance thumbnail in /api/v1/instance See merge request
pleroma/pleroma!55
parents
3fa6f3ae
03c15a54
Pipeline
#571
passed with stage
in 2 minutes and 16 seconds
Changes
3
Pipelines
1
Show whitespace changes
Inline
Side-by-side
lib/pleroma/web/endpoint.ex
View file @
0f194dc5
...
@@ -12,7 +12,7 @@ defmodule Pleroma.Web.Endpoint do
...
@@ -12,7 +12,7 @@ defmodule Pleroma.Web.Endpoint do
at:
"/media"
,
from:
"uploads"
,
gzip:
false
at:
"/media"
,
from:
"uploads"
,
gzip:
false
plug
Plug
.
Static
,
plug
Plug
.
Static
,
at:
"/"
,
from:
:pleroma
,
at:
"/"
,
from:
:pleroma
,
only:
~w(index.html static finmoji emoji packs sounds sw.js)
only:
~w(index.html static finmoji emoji packs sounds
instance
sw.js)
# Code reloading can be explicitly enabled under the
# Code reloading can be explicitly enabled under the
# :code_reloader configuration of your endpoint.
# :code_reloader configuration of your endpoint.
...
...
lib/pleroma/web/mastodon_api/mastodon_api_controller.ex
View file @
0f194dc5
...
@@ -103,6 +103,7 @@ def masto_instance(conn, _params) do
...
@@ -103,6 +103,7 @@ def masto_instance(conn, _params) do
streaming_api:
String
.
replace
(
Web
.
base_url
,
[
"http"
,
"https"
],
"wss"
)
streaming_api:
String
.
replace
(
Web
.
base_url
,
[
"http"
,
"https"
],
"wss"
)
},
},
stats:
Stats
.
get_stats
,
stats:
Stats
.
get_stats
,
thumbnail:
Web
.
base_url
<>
"/instance/thumbnail.jpeg"
,
max_toot_chars:
Keyword
.
get
(
@instance
,
:limit
)
max_toot_chars:
Keyword
.
get
(
@instance
,
:limit
)
}
}
...
...
priv/static/instance/thumbnail.jpeg
0 → 100644
View file @
0f194dc5
46.6 KB
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment