var functionCaller = function(name, context, index, currentFileInfo) { this.name = name.toLowerCase(); this.index = index; this.context = context; this.currentFileInfo = currentFileInfo; this.func = context.frames[0].functionRegistry.get(this.name); }; functionCaller.prototype.isValid = function() { return Boolean(this.func); }; functionCaller.prototype.call = function(args) { return this.func.apply(this, args); }; module.exports = functionCaller;