Minor changes

This commit is contained in:
Luke Towers 2018-11-05 14:35:58 -06:00
parent bba42c36e9
commit 32c7891942
2 changed files with 3 additions and 1 deletions

View File

@ -9,6 +9,8 @@ use October\Rain\Halcyon\Datasource\DatasourceInterface;
/**
* Datasource that loads from other data sources automatically
*
* @Todo: Need to prevent softdeleted DB records from appearing, even if they exist in the filesystem
*/
class AutoDatasource extends Datasource implements DatasourceInterface
{

View File

@ -519,7 +519,7 @@ class Theme
$enableDbLayer = !Config::get('app.debug');
}
if ($enableDbLayer) {
if ($enableDbLayer && App::hasDatabase()) {
$datasource = new AutoDatasource([
new DbDatasource($this->dirName, 'cms_theme_contents'),
new FileDatasource($this->getPath(), App::make('files')),