Skip to content

Commit

Permalink
Bugfix in ManagerEvent function. (#61)
Browse files Browse the repository at this point in the history
  • Loading branch information
davibaltar authored Jun 15, 2021
1 parent c3b4fb5 commit f8e7ea6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/ami.js
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ function ManagerReader(context, data) {

function ManagerEvent(context, event) {
var emits = [];
if (event.response && event.actionid) {
if (event.response && event.actionid && typeof event.response == "string") {
// This is the response to an Action
emits.push(this.emit.bind(this, event.actionid, (event.response.toLowerCase() == 'error') ? event : undefined, event));
emits.push(this.emit.bind(this, 'response', event));
Expand Down

0 comments on commit f8e7ea6

Please sign in to comment.