1
0
Fork 0
mirror of synced 2024-09-29 08:51:28 +13:00

getDevice

This commit is contained in:
fogelito 2024-06-16 12:49:34 +03:00
parent 610edc9584
commit d39060e0a8

View file

@ -1451,9 +1451,9 @@ App::setResource('deviceForBuilds', function ($project) {
return getDevice(APP_STORAGE_BUILDS . '/app-' . $project->getId()); return getDevice(APP_STORAGE_BUILDS . '/app-' . $project->getId());
}, ['project']); }, ['project']);
function getDevice(string $root, ?string $connection = null): Device function getDevice(string $root, string $connection = ''): Device
{ {
$connection = empty($connection) ? System::getEnv('_APP_CONNECTIONS_STORAGE', '') : System::getEnv($connection, ''); $connection = !empty($connection) ? $connection : System::getEnv('_APP_CONNECTIONS_STORAGE', '');
if (!empty($connection)) { if (!empty($connection)) {
$acl = 'private'; $acl = 'private';