You appear to be a bot. Output may be restricted
Description
Checks if a database exists.
Usage
$bool = Adapter::database_exists( $database );
Parameters
- $database
- ( string ) required – The database name.
Returns
bool
Source
File name: wordpress-seo/lib/migrations/adapter.php
Lines:
1 to 14 of 14
public function database_exists( $database ) { $ddl = 'SHOW DATABASES'; $result = $this->select_all( $ddl ); if ( \count( $result ) === 0 ) { return false; } foreach ( $result as $dbrow ) { if ( $dbrow['Database'] === $database ) { return true; } } return false; }