Unverified Commit 3f8e0373 authored by Alexander Færøy's avatar Alexander Færøy
Browse files

Use rand:uniform/1 instead of random:uniform/1.

parent b482b9ca
......@@ -88,10 +88,8 @@ reset(Name) ->
%% @end
-spec join(atom()) -> ok.
join(_Name) ->
%% @doc Wait until the start of the next interval.
%% @end
-spec wait(atom(), non_neg_integer()) -> non_neg_integer().
......@@ -141,7 +139,7 @@ take(N, Name, Limit, Version) when N >= 0 ->
%% receiving service, avoiding starvation from larger data protocol
%% messages consuming the rate of entire intervals when a low rate
%% is used.
case random:uniform(Previous) of
case rand:uniform(Previous) of
%% Allow message if the random number falls within
%% the range of tokens left in the bucket after take.
Rand when Rand =< Tokens ->
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment