Problem/Motivation
In Drupal\name\Plugin\views\filter\Fulltext::op_word() , Condition object is instantiated.
Per Creating an instance of the class Drupal\Core\Database\Query\Condition with the new keyword is deprecated and an API addition with the method Drupal\Core\Database\Query\Query::getConnection():
'Creating an instance of this class is deprecated in drupal:9.1.0 and is removed in drupal:10.0.0. Use Database::getConnection()->condition() instead.'
Steps to reproduce
Proposed resolution
Replace
$where = $this->operator == 'word' ? new Condition('OR') : new Condition('AND');
with
$where = $this->connection->condition($this->operator == 'word' ? 'OR' : 'AND');
Remaining tasks
User interface changes
API changes
Data model changes
Issue fork name-3350735
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
- 3350735-creating-instance-of
changes, plain diff MR !7
Comments
Comment #2
godotislateComment #4
godotislateOpened merge request.
Comment #6
bluegeek9 commentedI updated the minimum version to 9.1
Introduced in version: 9.1.0
Comment #8
heddnThanks for your contributions.