Skip to content

Commit beccaea

Browse files
authored
Merge branch 'master' into dav/classification-index
2 parents 57ec1fb + f4e3f09 commit beccaea

68 files changed

Lines changed: 1380 additions & 645 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

apps/dav/composer/composer/autoload_classmap.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -309,6 +309,7 @@
309309
'OCA\\DAV\\Server' => $baseDir . '/../lib/Server.php',
310310
'OCA\\DAV\\Settings\\AvailabilitySettings' => $baseDir . '/../lib/Settings/AvailabilitySettings.php',
311311
'OCA\\DAV\\Settings\\CalDAVSettings' => $baseDir . '/../lib/Settings/CalDAVSettings.php',
312+
'OCA\\DAV\\SetupChecks\\NeedsSystemAddressBookSync' => $baseDir . '/../lib/SetupChecks/NeedsSystemAddressBookSync.php',
312313
'OCA\\DAV\\Storage\\PublicOwnerWrapper' => $baseDir . '/../lib/Storage/PublicOwnerWrapper.php',
313314
'OCA\\DAV\\SystemTag\\SystemTagList' => $baseDir . '/../lib/SystemTag/SystemTagList.php',
314315
'OCA\\DAV\\SystemTag\\SystemTagMappingNode' => $baseDir . '/../lib/SystemTag/SystemTagMappingNode.php',

apps/dav/composer/composer/autoload_static.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -324,6 +324,7 @@ class ComposerStaticInitDAV
324324
'OCA\\DAV\\Server' => __DIR__ . '/..' . '/../lib/Server.php',
325325
'OCA\\DAV\\Settings\\AvailabilitySettings' => __DIR__ . '/..' . '/../lib/Settings/AvailabilitySettings.php',
326326
'OCA\\DAV\\Settings\\CalDAVSettings' => __DIR__ . '/..' . '/../lib/Settings/CalDAVSettings.php',
327+
'OCA\\DAV\\SetupChecks\\NeedsSystemAddressBookSync' => __DIR__ . '/..' . '/../lib/SetupChecks/NeedsSystemAddressBookSync.php',
327328
'OCA\\DAV\\Storage\\PublicOwnerWrapper' => __DIR__ . '/..' . '/../lib/Storage/PublicOwnerWrapper.php',
328329
'OCA\\DAV\\SystemTag\\SystemTagList' => __DIR__ . '/..' . '/../lib/SystemTag/SystemTagList.php',
329330
'OCA\\DAV\\SystemTag\\SystemTagMappingNode' => __DIR__ . '/..' . '/../lib/SystemTag/SystemTagMappingNode.php',

apps/dav/lib/AppInfo/Application.php

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@
8989
use OCA\DAV\Search\ContactsSearchProvider;
9090
use OCA\DAV\Search\EventsSearchProvider;
9191
use OCA\DAV\Search\TasksSearchProvider;
92+
use OCA\DAV\SetupChecks\NeedsSystemAddressBookSync;
9293
use OCA\DAV\UserMigration\CalendarMigrator;
9394
use OCA\DAV\UserMigration\ContactsMigrator;
9495
use OCP\AppFramework\App;
@@ -101,7 +102,6 @@
101102
use OCP\Config\BeforePreferenceSetEvent;
102103
use OCP\Contacts\IManager as IContactsManager;
103104
use OCP\Files\AppData\IAppDataFactory;
104-
use OCP\IServerContainer;
105105
use OCP\IUser;
106106
use Psr\Container\ContainerInterface;
107107
use Psr\Log\LoggerInterface;
@@ -124,12 +124,12 @@ public function register(IRegistrationContext $context): void {
124124
$c->get(LoggerInterface::class)
125125
);
126126
});
127-
$context->registerService(AppCalendarPlugin::class, function(ContainerInterface $c) {
127+
$context->registerService(AppCalendarPlugin::class, function (ContainerInterface $c) {
128128
return new AppCalendarPlugin(
129-
$c->get(ICalendarManager::class),
130-
$c->get(LoggerInterface::class)
129+
$c->get(ICalendarManager::class),
130+
$c->get(LoggerInterface::class)
131131
);
132-
});
132+
});
133133

134134
/*
135135
* Register capabilities
@@ -201,6 +201,8 @@ public function register(IRegistrationContext $context): void {
201201

202202
$context->registerUserMigrator(CalendarMigrator::class);
203203
$context->registerUserMigrator(ContactsMigrator::class);
204+
205+
$context->registerSetupCheck(NeedsSystemAddressBookSync::class);
204206
}
205207

206208
public function boot(IBootContext $context): void {
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
/**
6+
* @copyright Copyright (c) 2023 Anna Larch <anna.larch@gmx.net>
7+
*
8+
* @author Anna Larch <anna.larch@gmx.net>
9+
* @author Côme Chilliet <come.chilliet@nextcloud.com>
10+
*
11+
* @license GNU AGPL version 3 or any later version
12+
*
13+
* This program is free software: you can redistribute it and/or modify
14+
* it under the terms of the GNU Affero General Public License as
15+
* published by the Free Software Foundation, either version 3 of the
16+
* License, or (at your option) any later version.
17+
*
18+
* This program is distributed in the hope that it will be useful,
19+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
20+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21+
* GNU Affero General Public License for more details.
22+
*
23+
* You should have received a copy of the GNU Affero General Public License
24+
* along with this program. If not, see <https://www.gnu.org/licenses/>.
25+
*
26+
*/
27+
28+
namespace OCA\DAV\SetupChecks;
29+
30+
use OCP\IConfig;
31+
use OCP\IL10N;
32+
use OCP\SetupCheck\ISetupCheck;
33+
use OCP\SetupCheck\SetupResult;
34+
35+
class NeedsSystemAddressBookSync implements ISetupCheck {
36+
public function __construct(
37+
private IConfig $config,
38+
private IL10N $l10n,
39+
) {
40+
}
41+
42+
public function getName(): string {
43+
return $this->l10n->t('Checking for DAV system address book');
44+
}
45+
46+
public function getCategory(): string {
47+
return 'dav';
48+
}
49+
50+
public function run(): SetupResult {
51+
if ($this->config->getAppValue('dav', 'needs_system_address_book_sync', 'no') === 'no') {
52+
return SetupResult::success($this->l10n->t('No outstanding DAV system address book sync.'));
53+
} else {
54+
return SetupResult::warning($this->l10n->t('The DAV system address book sync has not run yet as your instance has more than 1000 users or because an error occurred. Please run it manually by calling occ dav:sync-system-addressbook.'));
55+
}
56+
}
57+
}

apps/files_sharing/src/components/SharingEntry.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,8 @@ export default {
158158
display: flex;
159159
flex-direction: column;
160160
justify-content: center;
161-
width: 80%;
162-
min-width: 80%;
161+
flex: 1 0;
162+
min-width: 0;
163163
164164
&__desc {
165165
display: inline-block;

apps/files_sharing/src/components/SharingEntryLink.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -755,8 +755,8 @@ export default {
755755
padding-left: 10px;
756756
display: flex;
757757
justify-content: space-between;
758-
width: 80%;
759-
min-width: 80%;
758+
flex: 1 0;
759+
min-width: 0;
760760
761761
&__desc {
762762
display: flex;

apps/settings/appinfo/routes.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@
6565
['name' => 'LogSettings#setLogLevel', 'url' => '/settings/admin/log/level', 'verb' => 'POST' , 'root' => ''],
6666
['name' => 'LogSettings#getEntries', 'url' => '/settings/admin/log/entries', 'verb' => 'GET' , 'root' => ''],
6767
['name' => 'LogSettings#download', 'url' => '/settings/admin/log/download', 'verb' => 'GET' , 'root' => ''],
68+
['name' => 'CheckSetup#setupCheckManager', 'url' => '/settings/setupcheck', 'verb' => 'GET' , 'root' => ''],
6869
['name' => 'CheckSetup#check', 'url' => '/settings/ajax/checksetup', 'verb' => 'GET' , 'root' => ''],
6970
['name' => 'CheckSetup#getFailedIntegrityCheckFiles', 'url' => '/settings/integrity/failed', 'verb' => 'GET' , 'root' => ''],
7071
['name' => 'CheckSetup#rescanFailedIntegrityCheck', 'url' => '/settings/integrity/rescan', 'verb' => 'GET' , 'root' => ''],

apps/settings/composer/composer/autoload_classmap.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,11 +74,13 @@
7474
'OCA\\Settings\\Settings\\Personal\\Security\\WebAuthn' => $baseDir . '/../lib/Settings/Personal/Security/WebAuthn.php',
7575
'OCA\\Settings\\Settings\\Personal\\ServerDevNotice' => $baseDir . '/../lib/Settings/Personal/ServerDevNotice.php',
7676
'OCA\\Settings\\SetupChecks\\CheckUserCertificates' => $baseDir . '/../lib/SetupChecks/CheckUserCertificates.php',
77-
'OCA\\Settings\\SetupChecks\\LdapInvalidUuids' => $baseDir . '/../lib/SetupChecks/LdapInvalidUuids.php',
77+
'OCA\\Settings\\SetupChecks\\DefaultPhoneRegionSet' => $baseDir . '/../lib/SetupChecks/DefaultPhoneRegionSet.php',
78+
'OCA\\Settings\\SetupChecks\\InternetConnectivity' => $baseDir . '/../lib/SetupChecks/InternetConnectivity.php',
7879
'OCA\\Settings\\SetupChecks\\LegacySSEKeyFormat' => $baseDir . '/../lib/SetupChecks/LegacySSEKeyFormat.php',
79-
'OCA\\Settings\\SetupChecks\\NeedsSystemAddressBookSync' => $baseDir . '/../lib/SetupChecks/NeedsSystemAddressBookSync.php',
8080
'OCA\\Settings\\SetupChecks\\PhpDefaultCharset' => $baseDir . '/../lib/SetupChecks/PhpDefaultCharset.php',
81+
'OCA\\Settings\\SetupChecks\\PhpOutdated' => $baseDir . '/../lib/SetupChecks/PhpOutdated.php',
8182
'OCA\\Settings\\SetupChecks\\PhpOutputBuffering' => $baseDir . '/../lib/SetupChecks/PhpOutputBuffering.php',
83+
'OCA\\Settings\\SetupChecks\\ReadOnlyConfig' => $baseDir . '/../lib/SetupChecks/ReadOnlyConfig.php',
8284
'OCA\\Settings\\SetupChecks\\SupportedDatabase' => $baseDir . '/../lib/SetupChecks/SupportedDatabase.php',
8385
'OCA\\Settings\\UserMigration\\AccountMigrator' => $baseDir . '/../lib/UserMigration/AccountMigrator.php',
8486
'OCA\\Settings\\UserMigration\\AccountMigratorException' => $baseDir . '/../lib/UserMigration/AccountMigratorException.php',

apps/settings/composer/composer/autoload_static.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,11 +89,13 @@ class ComposerStaticInitSettings
8989
'OCA\\Settings\\Settings\\Personal\\Security\\WebAuthn' => __DIR__ . '/..' . '/../lib/Settings/Personal/Security/WebAuthn.php',
9090
'OCA\\Settings\\Settings\\Personal\\ServerDevNotice' => __DIR__ . '/..' . '/../lib/Settings/Personal/ServerDevNotice.php',
9191
'OCA\\Settings\\SetupChecks\\CheckUserCertificates' => __DIR__ . '/..' . '/../lib/SetupChecks/CheckUserCertificates.php',
92-
'OCA\\Settings\\SetupChecks\\LdapInvalidUuids' => __DIR__ . '/..' . '/../lib/SetupChecks/LdapInvalidUuids.php',
92+
'OCA\\Settings\\SetupChecks\\DefaultPhoneRegionSet' => __DIR__ . '/..' . '/../lib/SetupChecks/DefaultPhoneRegionSet.php',
93+
'OCA\\Settings\\SetupChecks\\InternetConnectivity' => __DIR__ . '/..' . '/../lib/SetupChecks/InternetConnectivity.php',
9394
'OCA\\Settings\\SetupChecks\\LegacySSEKeyFormat' => __DIR__ . '/..' . '/../lib/SetupChecks/LegacySSEKeyFormat.php',
94-
'OCA\\Settings\\SetupChecks\\NeedsSystemAddressBookSync' => __DIR__ . '/..' . '/../lib/SetupChecks/NeedsSystemAddressBookSync.php',
9595
'OCA\\Settings\\SetupChecks\\PhpDefaultCharset' => __DIR__ . '/..' . '/../lib/SetupChecks/PhpDefaultCharset.php',
96+
'OCA\\Settings\\SetupChecks\\PhpOutdated' => __DIR__ . '/..' . '/../lib/SetupChecks/PhpOutdated.php',
9697
'OCA\\Settings\\SetupChecks\\PhpOutputBuffering' => __DIR__ . '/..' . '/../lib/SetupChecks/PhpOutputBuffering.php',
98+
'OCA\\Settings\\SetupChecks\\ReadOnlyConfig' => __DIR__ . '/..' . '/../lib/SetupChecks/ReadOnlyConfig.php',
9799
'OCA\\Settings\\SetupChecks\\SupportedDatabase' => __DIR__ . '/..' . '/../lib/SetupChecks/SupportedDatabase.php',
98100
'OCA\\Settings\\UserMigration\\AccountMigrator' => __DIR__ . '/..' . '/../lib/UserMigration/AccountMigrator.php',
99101
'OCA\\Settings\\UserMigration\\AccountMigratorException' => __DIR__ . '/..' . '/../lib/UserMigration/AccountMigratorException.php',

apps/settings/lib/AppInfo/Application.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,15 @@
4848
use OCA\Settings\Search\AppSearch;
4949
use OCA\Settings\Search\SectionSearch;
5050
use OCA\Settings\Search\UserSearch;
51+
use OCA\Settings\SetupChecks\CheckUserCertificates;
52+
use OCA\Settings\SetupChecks\DefaultPhoneRegionSet;
53+
use OCA\Settings\SetupChecks\InternetConnectivity;
54+
use OCA\Settings\SetupChecks\LegacySSEKeyFormat;
55+
use OCA\Settings\SetupChecks\PhpDefaultCharset;
56+
use OCA\Settings\SetupChecks\PhpOutdated;
57+
use OCA\Settings\SetupChecks\PhpOutputBuffering;
58+
use OCA\Settings\SetupChecks\ReadOnlyConfig;
59+
use OCA\Settings\SetupChecks\SupportedDatabase;
5160
use OCA\Settings\UserMigration\AccountMigrator;
5261
use OCA\Settings\WellKnown\ChangePasswordHandler;
5362
use OCA\Settings\WellKnown\SecurityTxtHandler;
@@ -137,6 +146,15 @@ public function register(IRegistrationContext $context): void {
137146
Util::getDefaultEmailAddress('no-reply')
138147
);
139148
});
149+
$context->registerSetupCheck(CheckUserCertificates::class);
150+
$context->registerSetupCheck(DefaultPhoneRegionSet::class);
151+
$context->registerSetupCheck(InternetConnectivity::class);
152+
$context->registerSetupCheck(LegacySSEKeyFormat::class);
153+
$context->registerSetupCheck(PhpDefaultCharset::class);
154+
$context->registerSetupCheck(PhpOutdated::class);
155+
$context->registerSetupCheck(PhpOutputBuffering::class);
156+
$context->registerSetupCheck(ReadOnlyConfig::class);
157+
$context->registerSetupCheck(SupportedDatabase::class);
140158

141159
$context->registerUserMigrator(AccountMigrator::class);
142160
}

0 commit comments

Comments
 (0)