storage device resource
This commit is contained in:
parent
0481a510a4
commit
b25cd9274c
1 changed files with 3 additions and 3 deletions
|
@ -825,11 +825,11 @@ App::setResource('dbForInternal', function($db, $cache, $project) {
|
|||
return $database;
|
||||
}, ['db', 'cache', 'project']);
|
||||
|
||||
App::setResource('storageSelf', function() {
|
||||
App::setResource('deviceLocal', function() {
|
||||
return new Local();
|
||||
});
|
||||
|
||||
App::setResource('storageFiles', function($project) {
|
||||
App::setResource('deviceFiles', function($project) {
|
||||
switch (App::getEnv('_APP_STORAGE_DEVICE', Storage::DEVICE_LOCAL)) {
|
||||
case Storage::DEVICE_LOCAL:default:
|
||||
return new Local(APP_STORAGE_UPLOADS . '/app-' . $project->getId());
|
||||
|
@ -850,7 +850,7 @@ App::setResource('storageFiles', function($project) {
|
|||
}
|
||||
}, ['project']);
|
||||
|
||||
App::setResource('storageFunctions', function($project) {
|
||||
App::setResource('deviceFunctions', function($project) {
|
||||
switch (App::getEnv('_APP_STORAGE_DEVICE', Storage::DEVICE_LOCAL)) {
|
||||
case Storage::DEVICE_LOCAL:default:
|
||||
return new Local(APP_STORAGE_FUNCTIONS . '/app-' . $project->getId());
|
||||
|
|
Loading…
Reference in a new issue