Note: this rule finds by the method name, so the object which has the method might not be an array.

The following patterns are considered problems:

varindexMap=myArray.reduce(function(memo,item,index){/*error Expected to return a value in this function.*/memo[item]=index;},{});varfoo=Array.from(nodes,function(node){/*error Expected to return a value at the end of this function.*/if(node.tagName==="DIV"){returntrue;}});varbar=foo.filter(function(x){if(x){returntrue;}else{return;/*error Expected a return value.*/}});