projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add native captcha and enable it by default.
[akkoma]
/
lib
/
pleroma
/
upload.ex
diff --git
a/lib/pleroma/upload.ex
b/lib/pleroma/upload.ex
index c47d6524111b3c40014b71b49a2a4d8d090f842d..9f0adde5b1da66ad07b8b812774784e698f829a0 100644
(file)
--- a/
lib/pleroma/upload.ex
+++ b/
lib/pleroma/upload.ex
@@
-228,7
+228,14
@@
defmodule Pleroma.Upload do
""
end
""
end
- [base_url, "media", path]
+ prefix =
+ if is_nil(Pleroma.Config.get([__MODULE__, :base_url])) do
+ "media"
+ else
+ ""
+ end
+
+ [base_url, prefix, path]
|> Path.join()
end
|> Path.join()
end