Skip to content

Commit

Permalink
WHISTLE-42: fix the logic for callback
Browse files Browse the repository at this point in the history
  • Loading branch information
k-anderson committed Jul 24, 2012
1 parent b5d264f commit 8449d1f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions whistle_apps/apps/callflow/src/module/cf_park.erl
Expand Up @@ -491,11 +491,11 @@ wait_for_pickup(SlotNumber, RingbackId, Call) ->
case whapps_call_command:b_hold(?DEFAULT_RINGBACK_TM, Call) of case whapps_call_command:b_hold(?DEFAULT_RINGBACK_TM, Call) of
{error, timeout} -> {error, timeout} ->
TmpCID = <<"Parking slot ", SlotNumber/binary>>, TmpCID = <<"Parking slot ", SlotNumber/binary>>,
Hungup = case whapps_call_command:channel_status(Call) of ChannelUp = case whapps_call_command:channel_status(Call) of
{ok, _} -> false; {ok, _} -> true;
{error, _} -> true {error, _} -> false
end, end,
case Hungup andalso ringback_parker(RingbackId, SlotNumber, TmpCID, Call) of case ChannelUp andalso ringback_parker(RingbackId, SlotNumber, TmpCID, Call) of
answered -> answered ->
lager:debug("parked caller ringback was answered"), lager:debug("parked caller ringback was answered"),
cf_exe:continue(Call); cf_exe:continue(Call);
Expand Down

0 comments on commit 8449d1f

Please sign in to comment.