Skip to content

Commit 41a47f8

Browse files
Merge pull request #54082 from nextcloud/fix/54080/using-userconfig-to-set-lang
2 parents f4ff7db + 132513d commit 41a47f8

File tree

5 files changed

+7
-48
lines changed

5 files changed

+7
-48
lines changed

core/AppInfo/ConfigLexicon.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@
2222
class ConfigLexicon implements ILexicon {
2323
public const SHAREAPI_ALLOW_FEDERATION_ON_PUBLIC_SHARES = 'shareapi_allow_federation_on_public_shares';
2424
public const SHARE_CUSTOM_TOKEN = 'shareapi_allow_custom_tokens';
25+
public const USER_LANGUAGE = 'lang';
26+
public const LASTCRON_TIMESTAMP = 'lastcron';
2527

2628
public function getStrictness(): Strictness {
2729
return Strictness::IGNORE;
@@ -47,10 +49,13 @@ public function getAppConfigs(): array {
4749
lazy: true,
4850
note: 'Shares with guessable tokens may be accessed easily. Shares with custom tokens will continue to be accessible after this setting has been disabled.',
4951
),
52+
new Entry(self::LASTCRON_TIMESTAMP, ValueType::INT, 0, 'timestamp of last cron execution'),
5053
];
5154
}
5255

5356
public function getUserConfigs(): array {
54-
return [];
57+
return [
58+
new Entry(self::USER_LANGUAGE, ValueType::STRING, null, 'language'),
59+
];
5560
}
5661
}

lib/composer/composer/autoload_classmap.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1218,7 +1218,6 @@
12181218
'OC\\Comments\\ManagerFactory' => $baseDir . '/lib/private/Comments/ManagerFactory.php',
12191219
'OC\\Config' => $baseDir . '/lib/private/Config.php',
12201220
'OC\\Config\\ConfigManager' => $baseDir . '/lib/private/Config/ConfigManager.php',
1221-
'OC\\Config\\Lexicon\\CoreConfigLexicon' => $baseDir . '/lib/private/Config/Lexicon/CoreConfigLexicon.php',
12221221
'OC\\Config\\UserConfig' => $baseDir . '/lib/private/Config/UserConfig.php',
12231222
'OC\\Console\\Application' => $baseDir . '/lib/private/Console/Application.php',
12241223
'OC\\Console\\TimestampFormatter' => $baseDir . '/lib/private/Console/TimestampFormatter.php',

lib/composer/composer/autoload_static.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1259,7 +1259,6 @@ class ComposerStaticInit749170dad3f5e7f9ca158f5a9f04f6a2
12591259
'OC\\Comments\\ManagerFactory' => __DIR__ . '/../../..' . '/lib/private/Comments/ManagerFactory.php',
12601260
'OC\\Config' => __DIR__ . '/../../..' . '/lib/private/Config.php',
12611261
'OC\\Config\\ConfigManager' => __DIR__ . '/../../..' . '/lib/private/Config/ConfigManager.php',
1262-
'OC\\Config\\Lexicon\\CoreConfigLexicon' => __DIR__ . '/../../..' . '/lib/private/Config/Lexicon/CoreConfigLexicon.php',
12631262
'OC\\Config\\UserConfig' => __DIR__ . '/../../..' . '/lib/private/Config/UserConfig.php',
12641263
'OC\\Console\\Application' => __DIR__ . '/../../..' . '/lib/private/Console/Application.php',
12651264
'OC\\Console\\TimestampFormatter' => __DIR__ . '/../../..' . '/lib/private/Console/TimestampFormatter.php',

lib/private/AppFramework/Bootstrap/RegistrationContext.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
namespace OC\AppFramework\Bootstrap;
1111

1212
use Closure;
13-
use OC\Config\Lexicon\CoreConfigLexicon;
1413
use OC\Support\CrashReport\Registry;
1514
use OCP\AppFramework\App;
1615
use OCP\AppFramework\Bootstrap\IRegistrationContext;
@@ -144,7 +143,7 @@ class RegistrationContext {
144143
private array $declarativeSettings = [];
145144

146145
/** @var array<array-key, string> */
147-
private array $configLexiconClasses = ['core' => CoreConfigLexicon::class];
146+
private array $configLexiconClasses = [];
148147

149148
/** @var ServiceRegistration<ITeamResourceProvider>[] */
150149
private array $teamResourceProviders = [];

lib/private/Config/Lexicon/CoreConfigLexicon.php

Lines changed: 0 additions & 43 deletions
This file was deleted.

0 commit comments

Comments
 (0)