Skip to content
This repository has been archived by the owner on Sep 20, 2024. It is now read-only.

Commit

Permalink
add proper support for string vs regex pattern
Browse files Browse the repository at this point in the history
  • Loading branch information
Ben Brown committed Sep 25, 2016
1 parent 1143fff commit bdbeff0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/Studio.js
Original file line number Diff line number Diff line change
Expand Up @@ -270,8 +270,10 @@ module.exports = function(controller) {

if (options.type == 'utterance') {
pattern = controller.utterances[options.pattern];
} else {
} else if (options.type == 'string') {
pattern = '^' + options.pattern + '$';
} else if (options.type == 'regex') {
pattern = options.pattern;
}

return {
Expand Down

0 comments on commit bdbeff0

Please sign in to comment.