Permalink
Browse files

KAZOO-818: Fix created/ended time on transactions apis

  • Loading branch information...
1 parent 5433520 commit 3a150f825d79be55a2a621798d9f5e580c5413a4 Peter Defebvre committed Apr 9, 2013
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/whistle_transactions-1.0.0/src/wht_util.erl
@@ -299,7 +299,7 @@ collapse_created_time(Call, JObj) ->
MaybeCreated = wh_json:get_integer_value(<<"created">>, JObj, 0),
case CurrentCreated < MaybeCreated of
'true' -> Call;
- 'false' -> wh_json:set_value(<<"end">>, MaybeCreated, Call)
+ 'false' -> wh_json:set_value(<<"created">>, MaybeCreated, Call)
end.
%%--------------------------------------------------------------------
@@ -314,7 +314,7 @@ collapse_ended_time(Call, JObj) ->
MaybeEnd = wh_json:get_integer_value(<<"created">>, JObj, 0),
case CurrentEnd > MaybeEnd of
'true' -> Call;
- 'false' -> wh_json:set_value(<<"end">>, MaybeEnd, Call)
+ 'false' -> wh_json:set_value(<<"ended">>, MaybeEnd, Call)
end.
%%--------------------------------------------------------------------

0 comments on commit 3a150f8

Please sign in to comment.