Skip to content

Commit

Permalink
sort user in directory consistently (2600hz#6013)
Browse files Browse the repository at this point in the history
  • Loading branch information
zzzming authored and jamesaimonetti committed Sep 6, 2019
1 parent a9960ee commit 7d3c3a1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions applications/callflow/src/module/cf_directory.erl
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,9 @@ handle(Data, Call) ->
end.

-spec directory_start(kapps_call:call(), directory(), directory_users()) -> 'ok'.
directory_start(Call, State, CurrUsers) ->
directory_start(Call, State, CurrUsers, 3).
directory_start(Call, #directory{sort_by=SortBy}=State, CurrUsers) ->
Users = sort_users(CurrUsers, SortBy),
directory_start(Call, State, Users, 3).

-spec directory_start(kapps_call:call(), directory(), directory_users(), non_neg_integer()) -> 'ok'.
directory_start(Call, _State, _CurrUsers, 0) ->
Expand Down

0 comments on commit 7d3c3a1

Please sign in to comment.