Skip to content

Commit

Permalink
Simplify function clauses on riak_kv_memory_backend:reset/2.
Browse files Browse the repository at this point in the history
  • Loading branch information
seancribbs committed Apr 10, 2012
1 parent 7b5f32d commit 113fd02
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/riak_kv_memory_backend.erl
Original file line number Diff line number Diff line change
Expand Up @@ -364,11 +364,7 @@ callback(_Ref, _Msg, State) ->
reset() ->
reset(app_helper:get_env(riak_kv, memory_backend), app_helper:get_env(riak_kv, storage_backend)).

reset(undefined, _) ->
{error, reset_disabled};
reset([], _) ->
{error, reset_disabled};
reset(Props, ?MODULE) when is_list(Props) ->
reset([_|_]=Props, ?MODULE) ->
case proplists:get_value(test, Props) of
true ->
{ok, Ring} = riak_core_ring_manager:get_my_ring(),
Expand Down

0 comments on commit 113fd02

Please sign in to comment.