original_string: protected function _modifyPredicate(&$predicate, $type, $field, $op, $value) {
          if (!$predicate) {
              $predicate = new Predicate($type);
  
          } else if ($predicate->getType() !== $type) {
              throw new ExistingPredicateException(sprintf('Predicate clause already created using "%s" conjunction', $predicate->getType()));
          }
  
          if ($field instanceof Closure) {
              $predicate->bindCallback($field, $this);
  
          } else if ($value !== null || in_array($op, [Expr::NULL, Expr::NOT_NULL], true)) {
              $predicate->add($field, $op, $value);
  
          } else if ($op === '!=') {
              $predicate->notEq($field, $value);
  
          } else {
              $predicate->eq($field, $op);
          }
  
          return $this;
      }
code: protected function _modifyPredicate(&$predicate, $type, $field, $op, $value) {
          if (!$predicate) {
              $predicate = new Predicate($type);
  
          } else if ($predicate->getType() !== $type) {
              throw new ExistingPredicateException(sprintf('Predicate clause already created using "%s" conjunction', $predicate->getType()));
          }
  
          if ($field instanceof Closure) {
              $predicate->bindCallback($field, $this);
  
          } else if ($value !== null || in_array($op, [Expr::NULL, Expr::NOT_NULL], true)) {
              $predicate->add($field, $op, $value);
  
          } else if ($op === '!=') {
              $predicate->notEq($field, $value);
  
          } else {
              $predicate->eq($field, $op);
          }
  
          return $this;
      }
code_tokens: protected function _modifyPredicate ( & $ predicate , $ type , $ field , $ op , $ value ) { if ( ! $ predicate ) { $ predicate = new Predicate ( $ type ) ; } else if ( $ predicate -> getType ( ) !== $ type ) { throw new ExistingPredicateException ( sprintf ( 'Predicate clause already created using "%s" conjunction' , $ predicate -> getType ( ) ) ) ; } if ( $ field instanceof Closure ) { $ predicate -> bindCallback ( $ field , $ this ) ; } else if ( $ value !== null || in_array ( $ op , [ Expr :: NULL , Expr :: NOT_NULL ] , true ) ) { $ predicate -> add ( $ field , $ op , $ value ) ; } else if ( $ op === '!=' ) { $ predicate -> notEq ( $ field , $ value ) ; } else { $ predicate -> eq ( $ field , $ op ) ; } return $ this ; }
docstring: Modify a predicate by adding additional clauses.
  
  @param \Titon\Db\Query\Predicate $predicate
  @param int $type
  @param string $field
  @param mixed $op
  @param mixed $value
  @return $this
  @throws \Titon\Db\Exception\ExistingPredicateException
docstring_tokens: Modify a predicate by adding additional clauses .