diff --git a/lib/plugins/blocks.js b/lib/plugins/blocks.js index e5efb7634..5d396516c 100644 --- a/lib/plugins/blocks.js +++ b/lib/plugins/blocks.js @@ -75,9 +75,10 @@ function inject (bot, { version }) { } } } + return null function isMatchingType (block) { - return options.matching.indexOf(block.type) >= 0 + return block === null ? false : options.matching.indexOf(block.type) >= 0 } }