public function markErrorIf($condition, $unlessNull=true){
        if($condition && ($this->value !==null || !$unlessNull)){
            list(, $caller) = debug_backtrace(false);
            $this->errors[$this->field] = $caller['function'];
        }
        return $this;
    }
public function markErrorIf($condition, $unlessNull=true){
        if($condition && ($this->value !==null || !$unlessNull)){
            list(, $caller) = debug_backtrace(false);
            $this->errors[$this->field] = $caller['function'];
        }
        return $this;
    }
public function markErrorIf ( $ condition , $ unlessNull = true ) { if ( $ condition && ( $ this -> value !== null || ! $ unlessNull ) ) { list ( , $ caller ) = debug_backtrace ( false ) ; $ this -> errors [ $ this -> field ] = $ caller [ 'function' ] ; } return $ this ; }
Simple record the error, the error is just the function name
Simple record the error the error is just the function name