mod_spam_filter: Don't create wrong dump file name
Don't attempt creation of the dump file while checking the validity of the "spam_dump_file" option, as the @HOST@ keyword can't be expanded at this point. Thanks to Nico Wellpott for reporting this issue.
This commit is contained in:
parent
cb0a14c89a
commit
fe121057f2
|
@ -108,10 +108,7 @@ depends(_Host, _Opts) ->
|
|||
-spec mod_opt_type(atom()) -> fun((term()) -> term()) | [atom()].
|
||||
mod_opt_type(spam_dump_file) ->
|
||||
fun(none) -> none;
|
||||
(File) ->
|
||||
{ok, Fd} = file:open(File, [append, raw]),
|
||||
ok = file:close(Fd),
|
||||
iolist_to_binary(File)
|
||||
(File) -> iolist_to_binary(File)
|
||||
end;
|
||||
mod_opt_type(spam_jids_file) ->
|
||||
fun(none) -> none;
|
||||
|
|
Loading…
Reference in New Issue