public function getFunction($isWithinClosure) { return $isWithinClosure ? $this->functionInClosure : $this->function; }