Received a Fatal Error when running the following command:
$ wp db search "hello" --path=/Users/andrew/wp/
Fatal error: Call to undefined function like_escape() in /Users/andrew/wp-cli/db-command/src/DB_Command.php on line 1081
Scenarios:
- When running the command inside the db-command directory, that is when the error appear.
- When running the command in my home directory, the error does not appear.
My environment:
$ wp --info
PHP binary: /usr/bin/php
PHP version: 5.6.30
php.ini used:
WP-CLI root dir: phar://wp-cli.phar
WP-CLI vendor dir: phar://wp-cli.phar/vendor
WP_CLI phar path: /Users/andrew/wp-cli/db-command
WP-CLI packages dir:
WP-CLI global config:
WP-CLI project config: /Users/andrew/wp-cli/db-command/wp-cli.yml
WP-CLI version: 1.4.1