mod_http_upload: Apply cosmetic changes

This commit is contained in:
Holger Weiss 2015-08-23 18:06:12 +02:00
parent 13e8c857ce
commit 374c1b6dfc
2 changed files with 7 additions and 8 deletions

View File

@ -227,8 +227,7 @@ init({ServerHost, Opts}) ->
ServiceURL = gen_mod:get_opt(service_url, Opts, ServiceURL = gen_mod:get_opt(service_url, Opts,
fun(<<"http://", _/binary>> = URL) -> URL; fun(<<"http://", _/binary>> = URL) -> URL;
(<<"https://", _/binary>> = URL) -> URL (<<"https://", _/binary>> = URL) -> URL
end, end),
undefined),
case ServiceURL of case ServiceURL of
undefined -> undefined ->
ok; ok;
@ -244,7 +243,7 @@ init({ServerHost, Opts}) ->
{ok, #state{server_host = ServerHost, host = Host, name = Name, {ok, #state{server_host = ServerHost, host = Host, name = Name,
access = Access, max_size = MaxSize, access = Access, max_size = MaxSize,
secret_length = SecretLength, jid_in_url = JIDinURL, secret_length = SecretLength, jid_in_url = JIDinURL,
docroot = expand_home(DocRoot), docroot = expand_home(str:strip(DocRoot, right, $/)),
put_url = expand_host(str:strip(PutURL, right, $/), ServerHost), put_url = expand_host(str:strip(PutURL, right, $/), ServerHost),
get_url = expand_host(str:strip(GetURL, right, $/), ServerHost), get_url = expand_host(str:strip(GetURL, right, $/), ServerHost),
service_url = expand_host(ServiceURL, ServerHost)}}. service_url = expand_host(ServiceURL, ServerHost)}}.