diff options
Diffstat (limited to 'apps/files')
39 files changed, 23 insertions, 59 deletions
diff --git a/apps/files/ajax/download.php b/apps/files/ajax/download.php index e6be330c9b3..25d70c7ebcf 100644 --- a/apps/files/ajax/download.php +++ b/apps/files/ajax/download.php @@ -46,7 +46,7 @@ if (!is_array($files_list)) { * the content must not be longer than 32 characters and must only contain * alphanumeric characters */ -if(isset($_GET['downloadStartSecret']) +if (isset($_GET['downloadStartSecret']) && !isset($_GET['downloadStartSecret'][32]) && preg_match('!^[a-zA-Z0-9]+$!', $_GET['downloadStartSecret']) === 1) { setcookie('ocDownloadStarted', $_GET['downloadStartSecret'], time() + 20, '/'); diff --git a/apps/files/lib/Activity/FavoriteProvider.php b/apps/files/lib/Activity/FavoriteProvider.php index 38d40fde047..9cf1255765b 100644 --- a/apps/files/lib/Activity/FavoriteProvider.php +++ b/apps/files/lib/Activity/FavoriteProvider.php @@ -32,7 +32,6 @@ use OCP\IURLGenerator; use OCP\L10N\IFactory; class FavoriteProvider implements IProvider { - const SUBJECT_ADDED = 'added_favorite'; const SUBJECT_REMOVED = 'removed_favorite'; @@ -97,7 +96,6 @@ class FavoriteProvider implements IProvider { * @since 11.0.0 */ public function parseShortVersion(IEvent $event) { - if ($event->getSubject() === self::SUBJECT_ADDED) { $event->setParsedSubject($this->l->t('Added to favorites')); if ($this->activityManager->getRequirePNG()) { @@ -128,7 +126,6 @@ class FavoriteProvider implements IProvider { * @since 11.0.0 */ public function parseLongVersion(IEvent $event, IEvent $previousEvent = null) { - if ($event->getSubject() === self::SUBJECT_ADDED) { $subject = $this->l->t('You added {file} to your favorites'); if ($this->activityManager->getRequirePNG()) { diff --git a/apps/files/lib/AppInfo/Application.php b/apps/files/lib/AppInfo/Application.php index dd7ea19ba4a..9ee705f11c3 100644 --- a/apps/files/lib/AppInfo/Application.php +++ b/apps/files/lib/AppInfo/Application.php @@ -47,7 +47,6 @@ use OCP\EventDispatcher\IEventDispatcher; use OCP\IContainer; class Application extends App { - public const APP_ID = 'files'; public function __construct(array $urlParams=[]) { diff --git a/apps/files/lib/BackgroundJob/CleanupDirectEditingTokens.php b/apps/files/lib/BackgroundJob/CleanupDirectEditingTokens.php index f3c473fb2fc..4b4f36663ab 100644 --- a/apps/files/lib/BackgroundJob/CleanupDirectEditingTokens.php +++ b/apps/files/lib/BackgroundJob/CleanupDirectEditingTokens.php @@ -27,7 +27,6 @@ use OC\BackgroundJob\TimedJob; use OCP\DirectEditing\IManager; class CleanupDirectEditingTokens extends TimedJob { - private const INTERVAL_MINUTES = 15 * 60; /** diff --git a/apps/files/lib/BackgroundJob/CleanupFileLocks.php b/apps/files/lib/BackgroundJob/CleanupFileLocks.php index 45729fd1e36..a69ee51bfb1 100644 --- a/apps/files/lib/BackgroundJob/CleanupFileLocks.php +++ b/apps/files/lib/BackgroundJob/CleanupFileLocks.php @@ -53,7 +53,7 @@ class CleanupFileLocks extends TimedJob { */ public function run($argument) { $lockingProvider = \OC::$server->getLockingProvider(); - if($lockingProvider instanceof DBLockingProvider) { + if ($lockingProvider instanceof DBLockingProvider) { $lockingProvider->cleanExpiredLocks(); } } diff --git a/apps/files/lib/BackgroundJob/DeleteOrphanedItems.php b/apps/files/lib/BackgroundJob/DeleteOrphanedItems.php index 5c0c92b6034..b0f91b70401 100644 --- a/apps/files/lib/BackgroundJob/DeleteOrphanedItems.php +++ b/apps/files/lib/BackgroundJob/DeleteOrphanedItems.php @@ -31,7 +31,6 @@ use OCP\DB\QueryBuilder\IQueryBuilder; * Delete all share entries that have no matching entries in the file cache table. */ class DeleteOrphanedItems extends TimedJob { - const CHUNK_SIZE = 200; /** @var \OCP\IDBConnection */ @@ -150,5 +149,4 @@ class DeleteOrphanedItems extends TimedJob { $this->logger->debug("$deletedEntries orphaned comment read marks deleted", ['app' => 'DeleteOrphanedItems']); return $deletedEntries; } - } diff --git a/apps/files/lib/BackgroundJob/TransferOwnership.php b/apps/files/lib/BackgroundJob/TransferOwnership.php index ec89adafa86..2498cc865ff 100644 --- a/apps/files/lib/BackgroundJob/TransferOwnership.php +++ b/apps/files/lib/BackgroundJob/TransferOwnership.php @@ -122,7 +122,6 @@ class TransferOwnership extends QueuedJob { } $this->mapper->delete($transfer); - } private function failedNotication(Transfer $transfer): void { diff --git a/apps/files/lib/Capabilities.php b/apps/files/lib/Capabilities.php index ad5c4e1b773..c46ad01af71 100644 --- a/apps/files/lib/Capabilities.php +++ b/apps/files/lib/Capabilities.php @@ -75,6 +75,4 @@ class Capabilities implements ICapability { ], ]; } - - } diff --git a/apps/files/lib/Collaboration/Resources/ResourceProvider.php b/apps/files/lib/Collaboration/Resources/ResourceProvider.php index d747253f8ff..b4a97afbb56 100644 --- a/apps/files/lib/Collaboration/Resources/ResourceProvider.php +++ b/apps/files/lib/Collaboration/Resources/ResourceProvider.php @@ -37,7 +37,6 @@ use OCP\IURLGenerator; use OCP\IUser; class ResourceProvider implements IProvider { - public const RESOURCE_TYPE = 'file'; /** @var IRootFolder */ diff --git a/apps/files/lib/Command/DeleteOrphanedFiles.php b/apps/files/lib/Command/DeleteOrphanedFiles.php index 2a63f344a92..c5072983ef4 100644 --- a/apps/files/lib/Command/DeleteOrphanedFiles.php +++ b/apps/files/lib/Command/DeleteOrphanedFiles.php @@ -32,7 +32,6 @@ use Symfony\Component\Console\Output\OutputInterface; * Delete all file entries that have no matching entries in the storage table. */ class DeleteOrphanedFiles extends Command { - const CHUNK_SIZE = 200; /** @@ -79,5 +78,4 @@ class DeleteOrphanedFiles extends Command { $output->writeln("$deletedEntries orphaned file cache entries deleted"); } - } diff --git a/apps/files/lib/Command/Scan.php b/apps/files/lib/Command/Scan.php index 024899e5f5c..c75073e428f 100644 --- a/apps/files/lib/Command/Scan.php +++ b/apps/files/lib/Command/Scan.php @@ -321,5 +321,4 @@ class Scan extends Base { } return $connection; } - } diff --git a/apps/files/lib/Command/TransferOwnership.php b/apps/files/lib/Command/TransferOwnership.php index 7ada9ce8820..b1d90452c23 100644 --- a/apps/files/lib/Command/TransferOwnership.php +++ b/apps/files/lib/Command/TransferOwnership.php @@ -115,5 +115,4 @@ class TransferOwnership extends Command { return 0; } - } diff --git a/apps/files/lib/Controller/AjaxController.php b/apps/files/lib/Controller/AjaxController.php index 00637cc0936..52b774915ea 100644 --- a/apps/files/lib/Controller/AjaxController.php +++ b/apps/files/lib/Controller/AjaxController.php @@ -33,7 +33,6 @@ use OCP\Files\NotFoundException; use OCP\IRequest; class AjaxController extends Controller { - public function __construct(string $appName, IRequest $request) { parent::__construct($appName, $request); } diff --git a/apps/files/lib/Controller/ApiController.php b/apps/files/lib/Controller/ApiController.php index 3819e07909d..2aa3b777225 100644 --- a/apps/files/lib/Controller/ApiController.php +++ b/apps/files/lib/Controller/ApiController.php @@ -339,5 +339,4 @@ class ApiController extends Controller { $node = $this->userFolder->get($folderpath); return $node->getType(); } - } diff --git a/apps/files/lib/Controller/TransferOwnershipController.php b/apps/files/lib/Controller/TransferOwnershipController.php index 43b198fe18b..fb3f3dffd6c 100644 --- a/apps/files/lib/Controller/TransferOwnershipController.php +++ b/apps/files/lib/Controller/TransferOwnershipController.php @@ -193,5 +193,4 @@ class TransferOwnershipController extends OCSController { return new DataResponse([], Http::STATUS_OK); } - } diff --git a/apps/files/lib/Controller/ViewController.php b/apps/files/lib/Controller/ViewController.php index 7c5d2a08b88..73ee589fdbc 100644 --- a/apps/files/lib/Controller/ViewController.php +++ b/apps/files/lib/Controller/ViewController.php @@ -205,7 +205,6 @@ class ViewController extends Controller { $navBarPositionPosition = 6; $currentCount = 0; foreach ($favElements['folders'] as $dir) { - $link = $this->urlGenerator->linkToRoute('files.view.index', ['dir' => $dir, 'view' => 'files']); $sortingValue = ++$currentCount; $element = [ diff --git a/apps/files/lib/Db/TransferOwnership.php b/apps/files/lib/Db/TransferOwnership.php index 73c39ccebd2..acde06a977c 100644 --- a/apps/files/lib/Db/TransferOwnership.php +++ b/apps/files/lib/Db/TransferOwnership.php @@ -57,6 +57,4 @@ class TransferOwnership extends Entity { $this->addType('fileId', 'integer'); $this->addType('nodeName', 'string'); } - - } diff --git a/apps/files/lib/Db/TransferOwnershipMapper.php b/apps/files/lib/Db/TransferOwnershipMapper.php index 2cca83ba178..e1e373eaab9 100644 --- a/apps/files/lib/Db/TransferOwnershipMapper.php +++ b/apps/files/lib/Db/TransferOwnershipMapper.php @@ -46,5 +46,4 @@ class TransferOwnershipMapper extends QBMapper { return $this->findEntity($qb); } - } diff --git a/apps/files/lib/Event/LoadAdditionalScriptsEvent.php b/apps/files/lib/Event/LoadAdditionalScriptsEvent.php index 51682be6a41..d9c80a23207 100644 --- a/apps/files/lib/Event/LoadAdditionalScriptsEvent.php +++ b/apps/files/lib/Event/LoadAdditionalScriptsEvent.php @@ -29,7 +29,6 @@ namespace OCA\Files\Event; use OCP\EventDispatcher\Event; class LoadAdditionalScriptsEvent extends Event { - private $hiddenFields = []; public function addHiddenField(string $name, string $value): void { diff --git a/apps/files/lib/Event/LoadSidebar.php b/apps/files/lib/Event/LoadSidebar.php index a16eb1439ee..8f3892c60c2 100644 --- a/apps/files/lib/Event/LoadSidebar.php +++ b/apps/files/lib/Event/LoadSidebar.php @@ -29,5 +29,4 @@ namespace OCA\Files\Event; use OCP\EventDispatcher\Event; class LoadSidebar extends Event { - } diff --git a/apps/files/lib/Exception/TransferOwnershipException.php b/apps/files/lib/Exception/TransferOwnershipException.php index dad5dc13679..2fe7287f88f 100644 --- a/apps/files/lib/Exception/TransferOwnershipException.php +++ b/apps/files/lib/Exception/TransferOwnershipException.php @@ -29,5 +29,4 @@ namespace OCA\Files\Exception; use Exception; class TransferOwnershipException extends Exception { - } diff --git a/apps/files/lib/Helper.php b/apps/files/lib/Helper.php index b3a62aee1c5..3431fb2ffc7 100644 --- a/apps/files/lib/Helper.php +++ b/apps/files/lib/Helper.php @@ -73,7 +73,7 @@ class Helper { * @return string icon URL */ public static function determineIcon($file) { - if($file['type'] === 'dir') { + if ($file['type'] === 'dir') { $icon = \OC::$server->getMimeTypeDetector()->mimeTypeIcon('dir'); // TODO: move this part to the client side, using mountType if ($file->isShared()) { @@ -81,7 +81,7 @@ class Helper { } elseif ($file->isMounted()) { $icon = \OC::$server->getMimeTypeDetector()->mimeTypeIcon('dir-external'); } - }else{ + } else { $icon = \OC::$server->getMimeTypeDetector()->mimeTypeIcon($file->getMimetype()); } @@ -234,7 +234,6 @@ class Helper { if (!empty($tags)) { foreach ($tags as $fileId => $fileTags) { - foreach ($fileList as $key => $fileData) { if ($fileId !== $fileData[$fileIdentifier]) { continue; diff --git a/apps/files/lib/Listener/LegacyLoadAdditionalScriptsAdapter.php b/apps/files/lib/Listener/LegacyLoadAdditionalScriptsAdapter.php index 8dddb079eb0..298d7194cde 100644 --- a/apps/files/lib/Listener/LegacyLoadAdditionalScriptsAdapter.php +++ b/apps/files/lib/Listener/LegacyLoadAdditionalScriptsAdapter.php @@ -55,5 +55,4 @@ class LegacyLoadAdditionalScriptsAdapter implements IEventListener { $event->addHiddenField($name, $value); } } - } diff --git a/apps/files/lib/Listener/LoadSidebarListener.php b/apps/files/lib/Listener/LoadSidebarListener.php index cc99c102081..902b6bd387a 100644 --- a/apps/files/lib/Listener/LoadSidebarListener.php +++ b/apps/files/lib/Listener/LoadSidebarListener.php @@ -43,5 +43,4 @@ class LoadSidebarListener implements IEventListener { // TODO: remove when all tabs migrated to the new api Util::addScript('files', 'fileinfomodel'); } - } diff --git a/apps/files/lib/Service/DirectEditingService.php b/apps/files/lib/Service/DirectEditingService.php index c33fbe5d883..91e6a0acbb2 100644 --- a/apps/files/lib/Service/DirectEditingService.php +++ b/apps/files/lib/Service/DirectEditingService.php @@ -82,5 +82,4 @@ class DirectEditingService { } return $capabilities; } - } diff --git a/apps/files/lib/Service/OwnershipTransferService.php b/apps/files/lib/Service/OwnershipTransferService.php index 3415a2fd9e7..a838eb45eab 100644 --- a/apps/files/lib/Service/OwnershipTransferService.php +++ b/apps/files/lib/Service/OwnershipTransferService.php @@ -317,5 +317,4 @@ class OwnershipTransferService { $progress->finish(); $output->writeln(''); } - } diff --git a/apps/files/lib/Settings/PersonalSettings.php b/apps/files/lib/Settings/PersonalSettings.php index 40f12b830ad..ff5bf164dea 100644 --- a/apps/files/lib/Settings/PersonalSettings.php +++ b/apps/files/lib/Settings/PersonalSettings.php @@ -31,7 +31,6 @@ use OCP\AppFramework\Http\TemplateResponse; use OCP\Settings\ISettings; class PersonalSettings implements ISettings { - public function getForm(): TemplateResponse { return new TemplateResponse(Application::APP_ID, 'settings-personal'); } @@ -43,5 +42,4 @@ class PersonalSettings implements ISettings { public function getPriority(): int { return 90; } - } diff --git a/apps/files/templates/appnavigation.php b/apps/files/templates/appnavigation.php index 8992d266e49..f57295e8887 100644 --- a/apps/files/templates/appnavigation.php +++ b/apps/files/templates/appnavigation.php @@ -12,7 +12,7 @@ script(\OCA\Files\AppInfo\Application::APP_ID, 'dist/files-app-settings'); } ?> - <?php if($_['quota'] === \OCP\Files\FileInfo::SPACE_UNLIMITED): ?> + <?php if ($_['quota'] === \OCP\Files\FileInfo::SPACE_UNLIMITED): ?> <li id="quota" class="pinned <?php p($pinned === 0 ? 'first-pinned ' : '') ?>"> <a href="#" class="icon-quota svg"> <p><?php p($l->t('%s used', [$_['usage']])); ?></p> @@ -66,15 +66,16 @@ script(\OCA\Files\AppInfo\Application::APP_ID, 'dist/files-app-settings'); * @return int Returns the pinned value */ function NavigationListElements($item, $l, $pinned) { - strpos($item['classes'] ?? '', 'pinned') !== false ? $pinned++ : ''; - ?> + strpos($item['classes'] ?? '', 'pinned') !== false ? $pinned++ : ''; ?> <li data-id="<?php p($item['id']) ?>" <?php if (isset($item['dir'])) { ?> data-dir="<?php p($item['dir']); ?>" <?php } ?> <?php if (isset($item['view'])) { ?> data-view="<?php p($item['view']); ?>" <?php } ?> <?php if (isset($item['expandedState'])) { ?> data-expandedstate="<?php p($item['expandedState']); ?>" <?php } ?> class="nav-<?php p($item['id']) ?> - <?php if (isset($item['classes'])) { p($item['classes']); } ?> + <?php if (isset($item['classes'])) { + p($item['classes']); + } ?> <?php p($pinned === 1 ? 'first-pinned' : '') ?> <?php if (isset($item['defaultExpandedState']) && $item['defaultExpandedState']) { ?> open<?php } ?>" <?php if (isset($item['folderPosition'])) { ?> folderposition="<?php p($item['folderPosition']); ?>" <?php } ?>> @@ -85,17 +86,17 @@ function NavigationListElements($item, $l, $pinned) { <?php NavigationElementMenu($item); - if (isset($item['sublist'])) { - ?> + if (isset($item['sublist'])) { + ?> <button class="collapse app-navigation-noclose" <?php if (sizeof($item['sublist']) == 0) { ?> style="display: none" <?php } ?>></button> <ul id="sublist-<?php p($item['id']); ?>"> <?php foreach ($item['sublist'] as $item) { $pinned = NavigationListElements($item, $l, $pinned); - } - ?> + } ?> </ul> - <?php } ?> + <?php + } ?> </li> @@ -127,5 +128,6 @@ function NavigationElementMenu($item) { </ul> </div> - <?php } + <?php + } } diff --git a/apps/files/templates/index.php b/apps/files/templates/index.php index 69ad73f1081..2bac8410f91 100644 --- a/apps/files/templates/index.php +++ b/apps/files/templates/index.php @@ -4,7 +4,7 @@ <?php if (!$_['isIE']) { ?> <input type="checkbox" class="hidden-visually" id="showgridview" - <?php if($_['showgridview']) { ?>checked="checked" <?php } ?>/> + <?php if ($_['showgridview']) { ?>checked="checked" <?php } ?>/> <label id="view-toggle" for="showgridview" class="button <?php p($_['showgridview'] ? 'icon-toggle-filelist' : 'icon-toggle-pictures') ?>" title="<?php p($l->t('Toggle grid view'))?>"></label> <?php } ?> diff --git a/apps/files/templates/list.php b/apps/files/templates/list.php index ff23c1aee95..ff79c771c0a 100644 --- a/apps/files/templates/list.php +++ b/apps/files/templates/list.php @@ -12,7 +12,7 @@ */ ?> <input type="hidden" name="permissions" value="" id="permissions"> <input type="hidden" id="free_space" value="<?php isset($_['freeSpace']) ? p($_['freeSpace']) : '' ?>"> - <?php if(isset($_['dirToken'])):?> + <?php if (isset($_['dirToken'])):?> <input type="hidden" id="publicUploadRequestToken" name="requesttoken" value="<?php p($_['requesttoken']) ?>" /> <input type="hidden" id="dirToken" name="dirToken" value="<?php p($_['dirToken']) ?>" /> <?php endif;?> diff --git a/apps/files/tests/Activity/Filter/GenericTest.php b/apps/files/tests/Activity/Filter/GenericTest.php index 89169a0e85c..eb55ab2699f 100644 --- a/apps/files/tests/Activity/Filter/GenericTest.php +++ b/apps/files/tests/Activity/Filter/GenericTest.php @@ -36,7 +36,6 @@ use Test\TestCase; * @group DB */ class GenericTest extends TestCase { - public function dataFilters() { return [ [Favorites::class], diff --git a/apps/files/tests/Activity/Setting/GenericTest.php b/apps/files/tests/Activity/Setting/GenericTest.php index 0ebb29d9de3..e741a3e02a8 100644 --- a/apps/files/tests/Activity/Setting/GenericTest.php +++ b/apps/files/tests/Activity/Setting/GenericTest.php @@ -34,7 +34,6 @@ use OCP\Activity\ISetting; use Test\TestCase; class GenericTest extends TestCase { - public function dataSettings() { return [ [FavoriteAction::class], diff --git a/apps/files/tests/BackgroundJob/DeleteOrphanedItemsJobTest.php b/apps/files/tests/BackgroundJob/DeleteOrphanedItemsJobTest.php index b7ef5387090..13ccc678b36 100644 --- a/apps/files/tests/BackgroundJob/DeleteOrphanedItemsJobTest.php +++ b/apps/files/tests/BackgroundJob/DeleteOrphanedItemsJobTest.php @@ -257,5 +257,4 @@ class DeleteOrphanedItemsJobTest extends \Test\TestCase { ->execute(); $this->cleanMapping('comments_read_markers'); } - } diff --git a/apps/files/tests/BackgroundJob/ScanFilesTest.php b/apps/files/tests/BackgroundJob/ScanFilesTest.php index b236f753adb..75557955d6a 100644 --- a/apps/files/tests/BackgroundJob/ScanFilesTest.php +++ b/apps/files/tests/BackgroundJob/ScanFilesTest.php @@ -150,5 +150,4 @@ class ScanFilesTest extends TestCase { $this->invokePrivate($this->scanFiles, 'run', [[]]); } - } diff --git a/apps/files/tests/Command/DeleteOrphanedFilesTest.php b/apps/files/tests/Command/DeleteOrphanedFilesTest.php index 8d6098ff18d..e0a8a72aba3 100644 --- a/apps/files/tests/Command/DeleteOrphanedFilesTest.php +++ b/apps/files/tests/Command/DeleteOrphanedFilesTest.php @@ -72,7 +72,7 @@ class DeleteOrphanedFilesTest extends TestCase { protected function tearDown(): void { $userManager = \OC::$server->getUserManager(); $user1 = $userManager->get($this->user1); - if($user1) { + if ($user1) { $user1->delete(); } diff --git a/apps/files/tests/Controller/ApiControllerTest.php b/apps/files/tests/Controller/ApiControllerTest.php index b35d9d7b95d..d347cffdd81 100644 --- a/apps/files/tests/Controller/ApiControllerTest.php +++ b/apps/files/tests/Controller/ApiControllerTest.php @@ -246,5 +246,4 @@ class ApiControllerTest extends TestCase { $this->assertEquals($expected, $actual); } - } diff --git a/apps/files/tests/Controller/ViewControllerTest.php b/apps/files/tests/Controller/ViewControllerTest.php index c00f30c890a..50eb40079a0 100644 --- a/apps/files/tests/Controller/ViewControllerTest.php +++ b/apps/files/tests/Controller/ViewControllerTest.php @@ -138,7 +138,7 @@ class ViewControllerTest extends TestCase { [$this->user->getUID(), 'files', 'show_grid', true], ]); - $this->config + $this->config ->expects($this->any()) ->method('getAppValue') ->willReturnArgument(2); diff --git a/apps/files/tests/HelperTest.php b/apps/files/tests/HelperTest.php index 6b824e8ead8..867d2dab4b0 100644 --- a/apps/files/tests/HelperTest.php +++ b/apps/files/tests/HelperTest.php @@ -31,7 +31,6 @@ * Class Helper */ class HelperTest extends \Test\TestCase { - private function makeFileInfo($name, $size, $mtime, $isDir = false) { return new \OC\Files\FileInfo( '/' . $name, diff --git a/apps/files/tests/Service/TagServiceTest.php b/apps/files/tests/Service/TagServiceTest.php index 8870c315947..ca6d98909ed 100644 --- a/apps/files/tests/Service/TagServiceTest.php +++ b/apps/files/tests/Service/TagServiceTest.php @@ -111,13 +111,14 @@ class TagServiceTest extends \Test\TestCase { ]) ->setMethods($methods) ->getMock(); - } protected function tearDown(): void { \OC_User::setUserId(''); $user = \OC::$server->getUserManager()->get($this->user); - if ($user !== null) { $user->delete(); } + if ($user !== null) { + $user->delete(); + } } public function testUpdateFileTags() { @@ -162,7 +163,6 @@ class TagServiceTest extends \Test\TestCase { } public function testFavoriteActivity() { - $subdir = $this->root->newFolder('subdir'); $file = $subdir->newFile('test.txt'); |