mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-08-13 01:26:58 +00:00
fix play_and_get_digits to unset the var if the regex didn't match. and fix ESL/IVR to include the regex
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@12921 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
@@ -75,13 +75,13 @@ sub setVar($;) {
|
||||
|
||||
sub playAndGetDigits($;) {
|
||||
my $self = shift;
|
||||
my ($min, $max, $tries, $to, $term, $file, $invalid_file, $var) = @_;
|
||||
my ($min, $max, $tries, $to, $term, $file, $invalid_file, $var, $regex) = @_;
|
||||
|
||||
if (!$self->{_esl}->connected()) {
|
||||
return undef;
|
||||
}
|
||||
|
||||
$self->execute("play_and_get_digits", "$min $max $tries $to $term $file $invalid_file $var");
|
||||
$self->execute("play_and_get_digits", "$min $max $tries $to $term $file $invalid_file $var $regex");
|
||||
|
||||
return $self->getVar($var);
|
||||
|
||||
|
Reference in New Issue
Block a user