Skip to content

Commit

Permalink
KZOO-37: address CI issue from cherry-pick
Browse files Browse the repository at this point in the history
  • Loading branch information
k-anderson committed Feb 10, 2020
1 parent af63380 commit e9dbeb4
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions core/kazoo_apps/src/kapps_maintenance.erl
Original file line number Diff line number Diff line change
Expand Up @@ -615,12 +615,14 @@ ensure_aggregates([Account|Accounts], Total) ->
-spec ensure_aggregate(kz_term:ne_binary()) -> 'ok'.
ensure_aggregate(Account) ->
ensure_aggregate(Account
,kz_datamgr:open_doc(Account, kz_util:format_account_id(Account))
,kz_datamgr:open_doc(kz_util:format_account_db(Account)
,kz_util:format_account_id(Account)
)
).

-spec ensure_aggregate(kz_term:ne_binary(), kz_datamgr:get_results_return()) -> 'ok'.
ensure_aggregate(Account, {'error', 'not_found'}) ->
io:format("skipping account db in bad state '~s'~n", [Account]);
io:format("necessary documents from account '~s' are missing, skipping migration~n", [Account]);
ensure_aggregate(Account, _) ->
io:format("ensuring necessary documents from account '~s' are in aggregate dbs~n"
,[Account]
Expand Down

0 comments on commit e9dbeb4

Please sign in to comment.