diff --git a/.github/workflows/phpunit-sqlite.yml b/.github/workflows/phpunit-sqlite.yml index 9a86fea1..d97f3fd8 100644 --- a/.github/workflows/phpunit-sqlite.yml +++ b/.github/workflows/phpunit-sqlite.yml @@ -27,8 +27,8 @@ jobs: strategy: matrix: - php-versions: ['7.4', '8.0', '8.1'] - server-versions: ['master'] + php-versions: ['8.0', '8.1', '8.2'] + server-versions: ['stable27'] steps: - name: Set app env @@ -53,7 +53,7 @@ jobs: with: php-version: ${{ matrix.php-versions }} tools: phpunit - extensions: mbstring, iconv, fileinfo, intl, sqlite, pdo_sqlite + extensions: mbstring, iconv, fileinfo, intl, sqlite, pdo_sqlite, zip, gd coverage: none - name: Check composer file existence diff --git a/composer.json b/composer.json index e3aa4901..ee6a3ac8 100644 --- a/composer.json +++ b/composer.json @@ -12,7 +12,7 @@ "phpunit/phpunit": "^9.5", "nextcloud/coding-standard": "^1.0.0", "vimeo/psalm": "^4.3.2", - "nextcloud/ocp": "dev-master" + "nextcloud/ocp": "dev-stable27" }, "config": { "optimize-autoloader": true, diff --git a/composer.lock b/composer.lock index 48d4f912..5e960c8f 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "0f9c2c9d696d264f7692e885b428fcdf", + "content-hash": "09f9e32e5d8af39409c8279f1d526edc", "packages": [], "packages-dev": [ { @@ -866,30 +866,29 @@ }, { "name": "nextcloud/ocp", - "version": "dev-master", + "version": "dev-stable27", "source": { "type": "git", "url": "https://github.com/nextcloud-deps/ocp.git", - "reference": "dea7e6cd566796f983ef54bafaba860f529116f3" + "reference": "a25af68d428145141ac85ae0746f70d9f04911e4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nextcloud-deps/ocp/zipball/dea7e6cd566796f983ef54bafaba860f529116f3", - "reference": "dea7e6cd566796f983ef54bafaba860f529116f3", + "url": "https://api.github.com/repos/nextcloud-deps/ocp/zipball/a25af68d428145141ac85ae0746f70d9f04911e4", + "reference": "a25af68d428145141ac85ae0746f70d9f04911e4", "shasum": "" }, "require": { - "php": "~8.0 || ~8.1 || ~8.2 || ~8.3", + "php": "^7.4 || ~8.0 || ~8.1", "psr/clock": "^1.0", "psr/container": "^2.0.2", "psr/event-dispatcher": "^1.0", "psr/log": "^1.1.4" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { - "dev-master": "30.0.0-dev" + "dev-stable27": "27.0.0-dev" } }, "notification-url": "https://packagist.org/downloads/", @@ -905,9 +904,9 @@ "description": "Composer package containing Nextcloud's public API (classes, interfaces)", "support": { "issues": "https://github.com/nextcloud-deps/ocp/issues", - "source": "https://github.com/nextcloud-deps/ocp/tree/master" + "source": "https://github.com/nextcloud-deps/ocp/tree/stable27" }, - "time": "2024-04-18T10:48:36+00:00" + "time": "2024-06-05T00:35:15+00:00" }, { "name": "nikic/php-parser", @@ -3589,5 +3588,5 @@ "platform-overrides": { "php": "8.0" }, - "plugin-api-version": "2.3.0" + "plugin-api-version": "2.6.0" } diff --git a/lib/AppInfo/Application.php b/lib/AppInfo/Application.php index 8bc4402e..4e3537a8 100644 --- a/lib/AppInfo/Application.php +++ b/lib/AppInfo/Application.php @@ -28,7 +28,7 @@ use OCP\AppFramework\Bootstrap\IRegistrationContext; class Application extends App implements IBootstrap { - public function __construct(array $urlParams = array()) { + public function __construct(array $urlParams = []) { parent::__construct('survey_client', $urlParams); } diff --git a/lib/BackgroundJobs/AdminNotification.php b/lib/BackgroundJobs/AdminNotification.php index 06659b6b..411756dc 100644 --- a/lib/BackgroundJobs/AdminNotification.php +++ b/lib/BackgroundJobs/AdminNotification.php @@ -33,9 +33,9 @@ class AdminNotification extends QueuedJob { protected IURLGenerator $url; public function __construct(ITimeFactory $time, - IManager $manager, - IGroupManager $groupManager, - IURLGenerator $url) { + IManager $manager, + IGroupManager $groupManager, + IURLGenerator $url) { parent::__construct($time); $this->manager = $manager; $this->groupManager = $groupManager; diff --git a/lib/BackgroundJobs/MonthlyReport.php b/lib/BackgroundJobs/MonthlyReport.php index c427cc5b..086b0561 100644 --- a/lib/BackgroundJobs/MonthlyReport.php +++ b/lib/BackgroundJobs/MonthlyReport.php @@ -33,8 +33,8 @@ class MonthlyReport extends TimedJob { protected LoggerInterface $logger; public function __construct(ITimeFactory $time, - Collector $collector, - LoggerInterface $logger) { + Collector $collector, + LoggerInterface $logger) { parent::__construct($time); $this->collector = $collector; $this->logger = $logger; diff --git a/lib/Categories/Database.php b/lib/Categories/Database.php index 30846d17..0fd76b3b 100644 --- a/lib/Categories/Database.php +++ b/lib/Categories/Database.php @@ -150,7 +150,7 @@ protected function databaseSize() { if ($row['proname'] === 'pg_database_size') { $database = $this->config->getSystemValue('dbname'); if (strpos($database, '.') !== false) { - list($database, ) = explode('.', $database); + [$database, ] = explode('.', $database); } $sql = "SELECT oid FROM pg_database diff --git a/lib/Controller/EndpointController.php b/lib/Controller/EndpointController.php index be7d925b..35c3a374 100644 --- a/lib/Controller/EndpointController.php +++ b/lib/Controller/EndpointController.php @@ -23,14 +23,14 @@ namespace OCA\Survey_Client\Controller; -use OCA\Survey_Client\Collector; +use OCA\Survey_Client\BackgroundJobs\MonthlyReport; +use OCA\Survey_Client\Collector; use OCP\AppFramework\Http\DataResponse; use OCP\AppFramework\OCSController; use OCP\BackgroundJob\IJobList; use OCP\IRequest; use OCP\Notification\IManager; -use OCA\Survey_Client\BackgroundJobs\MonthlyReport; class EndpointController extends OCSController { @@ -51,10 +51,10 @@ class EndpointController extends OCSController { * @param IManager $manager */ public function __construct(string $appName, - IRequest $request, - Collector $collector, - IJobList $jobList, - IManager $manager) { + IRequest $request, + Collector $collector, + IJobList $jobList, + IManager $manager) { parent::__construct($appName, $request); $this->collector = $collector; diff --git a/lib/Migration/SendAdminNotification.php b/lib/Migration/SendAdminNotification.php index ea15d0de..80b5f213 100644 --- a/lib/Migration/SendAdminNotification.php +++ b/lib/Migration/SendAdminNotification.php @@ -26,11 +26,11 @@ namespace OCA\Survey_Client\Migration; +use OCA\Survey_Client\BackgroundJobs\AdminNotification; +use OCA\Survey_Client\BackgroundJobs\MonthlyReport; use OCP\BackgroundJob\IJobList; use OCP\Migration\IOutput; use OCP\Migration\IRepairStep; -use OCA\Survey_Client\BackgroundJobs\MonthlyReport; -use OCA\Survey_Client\BackgroundJobs\AdminNotification; class SendAdminNotification implements IRepairStep { /** @var IJobList */ diff --git a/lib/Settings/AdminSettings.php b/lib/Settings/AdminSettings.php index b17f4fb5..e8951f8a 100644 --- a/lib/Settings/AdminSettings.php +++ b/lib/Settings/AdminSettings.php @@ -48,10 +48,10 @@ class AdminSettings implements ISettings { private $jobList; public function __construct(Collector $collector, - IConfig $config, - IL10N $l, - IDateTimeFormatter $dateTimeFormatter, - IJobList $jobList + IConfig $config, + IL10N $l, + IDateTimeFormatter $dateTimeFormatter, + IJobList $jobList ) { $this->collector = $collector; $this->config = $config; diff --git a/templates/admin.php b/templates/admin.php index 0fb72a36..1f1f316c 100644 --- a/templates/admin.php +++ b/templates/admin.php @@ -56,7 +56,7 @@

+?>