Permalink
Browse files

Merge pull request #519 from basho/bugfix/unknown-security-capability

If the security capability is unknown, consider security off
  • Loading branch information...
Vagabond committed Feb 5, 2014
2 parents 92f614f + 5346857 commit b69bfe3e2e4e0116c3a1f76ee5793ccff33e8465
Showing with 4 additions and 1 deletion.
  1. +4 −1 src/riak_core_security.erl
@@ -507,7 +507,7 @@ del_source(User, CIDR) ->
is_enabled() ->
- case riak_core_capability:get({riak_core, security}) of
+ try riak_core_capability:get({riak_core, security}) of
true ->
case riak_core_metadata:get({<<"security">>, <<"status">>},
enabled) of
@@ -518,6 +518,9 @@ is_enabled() ->
end;
_ ->
false
+ catch
+ throw:{unknown_capability, {riak_core, security}} ->
+ false
end.
enable() ->

0 comments on commit b69bfe3

Please sign in to comment.