Commit graph

1009 commits

Author SHA1 Message Date
Côme Chilliet
ebab99ec9a
Merge pull request #56779 from nextcloud/jtr/needUpgrade-refactor
feat: improve needUpgrade() output and refactor for clarity
2026-01-06 14:04:13 +01:00
Ferdinand Thiessen
105398699d
Merge pull request #56780 from nextcloud/jtr/chore-drop-getUserQuota-legacy
chore(legacy): Remove deprecated getUserQuota method
2025-12-23 18:09:32 +01:00
Carl Schwan
6945a030f5
refactor(OC_Helper): remove buildNotExistingFileNameForView
Move the functionality in the last place it is used OC\Files\Node\Folder

Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-12-16 10:38:29 +01:00
Josh
d95ce6ac92
chore: drop no longer needed runningOnMac method
Removed deprecated method 'runningOnMac' that checks if PHP is running on macOS.

Signed-off-by: Josh <josh.t.richards@gmail.com>
2025-12-04 16:46:55 -05:00
Carl Schwan
f38c8c3d7c
fix(formatting): Fix formatting issue
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-12-03 11:10:18 +01:00
Josh
cc873ccaec chore(legacy): deprecate OC_Util::runningOnMac()
- Easy enough query directly these days; Only used in one spot anyhow
- Updated the runningOnMac method to use PHP_OS_FAMILY just for clarity until we can remove the function entirely (same result; supported since PHP ~7.4).

Signed-off-by: Josh <josh.t.richards@gmail.com>
2025-12-02 21:52:58 -05:00
Josh
33fba8c084
chore(legacy): Remove deprecated getUserQuota method
Formally deprecated with 9.0.0 and we dropped final uses of it in #53045.

Signed-off-by: Josh <josh.t.richards@gmail.com>
2025-12-01 12:49:27 -05:00
Josh
3de06a2b33
chore: lint happiness
Signed-off-by: Josh <josh.t.richards@gmail.com>
2025-12-01 12:26:03 -05:00
Josh
d3432482cc
feat: improve needUpgrade() output and refactor for clarity
- Reorganized logic to improve clarity + eliminate duplication
- Switched app handling to non-deprecated IAppManager API
- Make the HintException clearer and more actionable
- Log disallowed downgrade attempts before throwing

Signed-off-by: Josh <josh.t.richards@gmail.com>
2025-12-01 12:10:52 -05:00
Côme Chilliet
bdff12361c
fix: Cleanup and fix tests, and fix related issues in code
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-09-30 11:53:59 +02:00
Côme Chilliet
2bc77a3c5a
chore: Remove now unused OC_App deprecated methods
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-09-29 12:36:33 +02:00
Côme Chilliet
f4e8116a72
Merge pull request #55387 from nextcloud/fix/remove-legacy-oc-response
fix: Delete legacy OC_Response
2025-09-29 10:40:28 +02:00
Côme Chilliet
10e3192c2f
Merge pull request #55371 from nextcloud/carl/remove-oc-helper-streamCopy
refactor: Remove OC_Helper::streamCopy
2025-09-29 10:21:59 +02:00
Côme Chilliet
eb54143c2d
fix: Delete legacy OC_Response
Moved the last used method in base.php where it’s called. Ideally we
 would remove it but it’s not clear whether that would be possible any
 time soon or even at all.

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-09-29 09:35:32 +02:00
Côme Chilliet
d39d1d8d24
chore: Remove unused deprecated methods from OC_User and Filesystem
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-09-28 22:44:30 +02:00
Carl Schwan
8e5eef24d2 refactor: Remove OC_Helper::streamCopy
Replace by Files::streamCopy, also deprecated but since less long

Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-09-28 12:52:14 +02:00
Carl Schwan
4ae4b0a0e7 refactor: Remove old TemplateManager
Not used anymore

Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-09-28 12:48:41 +02:00
Ferdinand Thiessen
660f3f6fd1
refactor: use logical && || instead of weak and or operators
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-09-27 23:02:18 +02:00
Josh
130cb05ea4 chore: remove mbstring.func_overload check from checkserver()
Signed-off-by: Josh <josh.t.richards@gmail.com>
2025-08-25 13:19:36 +02:00
Côme Chilliet
12edd2b23a
fix: Deduplicate code by using DependencyAnalyzer in the AppManager
Was a bit more complicated than expected because of a dependency loop,
the L10N factory uses the app manager, thus the AppManager cannot depend
on I10N directly or indirectly in its constructor.

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-08-18 17:09:40 +02:00
Côme Chilliet
0e01bc09a9
chore: Inline OC_App::setupBackgroundJobs
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-08-18 17:09:39 +02:00
Côme Chilliet
e5606d7fe3
chore: Move getAppPath and getAppWebPath implementations into AppManager
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-08-18 17:09:39 +02:00
Côme Chilliet
3e01a429e7
chore: Replace last calls to OC_App::enable by IAppManager
Also added a few missing deprecations

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-08-18 17:09:39 +02:00
Côme Chilliet
4abfd4871f
chore: Move isAppCompatible and shouldUpgrade to the app manager
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-08-18 16:18:38 +02:00
Côme Chilliet
410389867c
chore: Inline private method OC_App::setupLiveMigrations
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-08-18 16:15:27 +02:00
Côme Chilliet
fd17555333
chore: Move OC_App::updateApp to IAppManager::upgradeApp
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-08-18 16:14:45 +02:00
Ferdinand Thiessen
d5e2432bcd
fix: resolve invalid usage of AppConfig::getValue
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-08-18 13:24:18 +02:00
Daniel Calviño Sánchez
4fcadd630b fix: Throw specific LoginException when the user is disabled
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2025-07-10 15:09:25 +02:00
Côme Chilliet
edf096a09f
chore: Check if apps directory is really writable in Installer
...rather than checkServer.

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-07-10 11:31:59 +02:00
Côme Chilliet
12c0cfc977
fix: Move getInstallPath to Installer class
This method does not need a public API for now, it’s only used
 internally.

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-07-10 09:39:58 +02:00
Côme Chilliet
1f5e232314
chore: Move info parsing related method from OC_App to InfoParser
Also fix the tests

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2025-07-08 15:57:05 +02:00
Ferdinand Thiessen
5981b7eb51
chore: apply new CSFixer rules
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>

# Conflicts:
#	apps/settings/lib/SetupChecks/PhpOpcacheSetup.php
2025-07-01 16:26:50 +02:00
Joas Schilling
60b8384e48
Merge branch 'master' into remove-x-xss-protection 2025-06-30 21:32:22 +02:00
Robin Appelman
1d2b991bda fix: don't create an empty file before writing the contents in OC_Util::copyr
Signed-off-by: Robin Appelman <robin@icewind.nl>
2025-06-24 16:27:27 +02:00
Maxence Lange
d8fc08d718 feat(lexicon): fix tests
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
2025-06-24 12:10:57 -01:00
Maxence Lange
3d3c77b774 feat(lexicon): migrate keys on app update
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
2025-06-24 12:10:57 -01:00
invario
2b58f74cc8
Fix: Remove X-XSS-Protection use, check and recommendation
Co-authored-by: John Molakvoæ <skjnldsv@users.noreply.github.com>
Signed-off-by: invario <67800603+invario@users.noreply.github.com>
2025-06-13 16:12:27 -04:00
Ferdinand Thiessen
c21e189850
fix: make core application bootstrapable by coordinator
Co-authored-by: Ferdinand Thiessen <opensource@fthiessen.de>
Co-authored-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com>
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-06-02 15:58:54 +02:00
Ferdinand Thiessen
e143921896
feat(IUser): add getQuotaBytes method to get machine readable quota
Proper replacement for deprecated `OC_Util::getUserQuota`.
Also we still use this in some cases we can now replace, moreover it
just makes sense to have a machine readable format in the API instead of
only the human readable format which is less precise.
Alings also with `getQuota` of the quota storage, which already returned
the machine readable format.

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-05-22 12:50:38 +02:00
Ferdinand Thiessen
22889d4f1d
chore: deprecate OC_Helper::isReadOnlyConfigEnabled
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-05-17 13:18:49 +02:00
Ferdinand Thiessen
e2a331f53d
Merge pull request #52890 from nextcloud/chore/move-stream-copy-implementation
chore: move streamCopy implementation from `OC_Helper` to `OCP\Files`
2025-05-17 12:01:44 +02:00
Ferdinand Thiessen
3d33091d2c
chore!: remove legacy functions from OC_Helper deprecated before v10
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-05-16 22:57:50 +02:00
Ferdinand Thiessen
bd91db8e20
chore: deprecate OC_Helper::copyr
Inline it into Installer as needed.

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-05-16 17:32:45 +02:00
Ferdinand Thiessen
01db539d0a
chore: move streamCopy implementation from OC_Helper to OCP\Files
The function was already there but called the legacy version.
So moved the implementation and migrated all usages of it.
Sadly the interface was slightly different so adjusted it to be
compatible with both legacy and the OCP one.

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-05-16 13:03:05 +02:00
Ferdinand Thiessen
802def31f2
chore: move implementation to non-deprecated OCP\Util from OC_Helper
Only moves the implementation where it was already existing and adds
more helpful deprecation messages.
This way we can in the future just remove the OC_Helper variants.

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-05-16 10:56:58 +02:00
Ferdinand Thiessen
54eaad76c0
chore!(\OCP\Files): remove deprecated static getStorage method
Was deprecated since Nextcloud 14 and is not used anymore.
Removing allows us to clean the OCP psalm baseline.

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-05-15 14:18:28 +02:00
John Molakvoæ
b3b63020c9
Merge pull request #52812 from nextcloud/chore/oc-helper-rmdirr 2025-05-14 21:53:47 +02:00
Ferdinand Thiessen
072d4e8cba
chore: move implementation from OC legacy to OCP\Files
- move implementation to the OCP variant that called the legacy before
- add the missing deprecation notice
- add missing parameter to align both signatures
- use OCP\Files where this method is still used

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-05-14 14:55:45 +02:00
Ferdinand Thiessen
1c7e4a1ba6
Merge pull request #52801 from nextcloud/chore/oc-helper-filesize
chore: replace legacy OC_Helper calls with OCP\Util
2025-05-14 14:37:13 +02:00
Ferdinand Thiessen
1ae3fa4003
chore: replace leagcy OC_Helper calls with OCP\Util
- Replace legacy calls with OCP\Util
- Add missing deprecation notices
- Inline implementation in OCP\Util and call it from OC_Helper

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-05-14 10:18:04 +02:00