lithium\data\source\http\adapter\CouchDb::_autoBuild()
Helper used for auto building a CouchDB database.
Parameters
-
string
$result
A query result.
Source
protected function _autoBuild($result) {
$hasError = (
isset($result['error']) &&
isset($result['reason']) &&
$result['reason'] === "no_db_file"
);
if ($hasError) {
$this->connection->put($this->_config['database']);
return true;
}
return false;
}