private table_exists ( string $table_name ) : boolean | ||
$table_name | string | The name of a table. |
return | boolean | Whether or not a table with the given name exists in the database. |
private function table_exists($table_name)
{
$query = $this->db->prepare('SHOW TABLES LIKE %s', $table_name);
return (bool) $this->db->query($query);
}