Legacy storage is defined by an empty string.
`StorageManager::setBackend()` now accept an empty string as a valid
backend storage.
}
/**
- * @brief Return current storage backend class
+ * @brief Return current storage backend class
+ *
* @return string
* @throws \Friendica\Network\HTTPException\InternalServerErrorException
*/
/**
* @brief Set current storage backend class
+ * If $class is an empty string, legacy db storage is used.
*
* @param string $class Backend class name
* @return bool
*/
public static function setBackend($class)
{
- if (!in_array('Friendica\Model\Storage\IStorage', class_implements($class))) {
+ if ($class !== "" && !in_array('Friendica\Model\Storage\IStorage', class_implements($class))) {
return false;
}