Commit Graph

232 Commits (feat/database/query-result-fetch-associative-fetch-num)

Author SHA1 Message Date
Robin Appelman 9f1d497a0b
Merge pull request #38261 from fsamapoor/replace_strpos_calls_in_lib_private
Refactors "strpos" calls in  lib/private to improve code readability.
2023-06-01 23:10:00 +07:00
Faraz Samapoor e7cc7653b8 Refactors "strpos" calls in lib/private to improve code readability.
Signed-off-by: Faraz Samapoor <fsamapoor@gmail.com>
2023-05-15 15:17:19 +07:00
Julius Härtl 0ebb00d01d
fix: Do not attempt to use l10n files as sources for combined js files
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2023-05-15 08:29:05 +07:00
Ferdinand Thiessen 31c01fa3da fix(JSResourceLocator): Handle missing translations silently
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2023-05-11 18:22:24 +07:00
Ferdinand Thiessen a3595f73ac fix(OC/Template): Allow `.mjs` files within custom app paths
If apps are installed in non standard app paths, we need
to check `$app_path/$script` instead of only doing so for translations.
Without this it would fallback to `.js` extension even if a `.mjs` file exists.

Also tried make the code more selfe explaining.

Signed-off-by: Ferdinand Thiessen <rpm@fthiessen.de>
2023-02-22 21:19:37 +07:00
Ferdinand Thiessen 00e041b907 feat(template): Allow `JSResourceLocator` to find ES6 scripts
Enable module js (ES6) support on the `JSResourceLocator`.
This changes `JSResourceLocator` to look for `.mjs` files first
to allow applications to provide a fallback `.js` for older Nextcloud versions.

Signed-off-by: Ferdinand Thiessen <rpm@fthiessen.de>
2023-02-22 21:19:37 +07:00
Ferdinand Thiessen dbb1fa1273 fix(OC/Template): Remove usage of deprecated functions in `JSResourceLocator`
Move from `\OC_App::getAppPath` to `IAppManager::getAppPath`.

Signed-off-by: Ferdinand Thiessen <rpm@fthiessen.de>
2023-02-22 21:19:37 +07:00
Julius Härtl 4cebfa95e6
fix: Fix loading styles from core/css/
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2023-02-20 09:28:30 +07:00
Côme Chilliet f5c361cf44
composer run cs:fix
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-01-20 11:45:08 +07:00
Thomas Citharel 34ce53355a
Catch NotFoundException as well in JSCombiner
Follow-up to #35576

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2022-12-08 11:50:50 +07:00
Julius Härtl 4bcaeb6c2c
Drop 3rdparty root since it is unused and adjust tests
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-12-07 23:55:32 +07:00
Julius Härtl 3e5838198c
Use single resource locator instance
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-12-07 22:32:05 +07:00
John Molakvoæ 2d98cd1daf
Add config and fix selenium
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
2022-10-19 10:04:51 +07:00
Carl Schwan 54031e370a Fix various other small psalm issues
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2022-10-17 12:40:35 +07:00
Carl Schwan de168b38e9
Make it possible to load theme/<themename>/dist
This fix a regression with the theming api following the change in
webpack bundling introduced in 24

Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2022-08-26 13:46:29 +07:00
Christopher Ng 7a13388fe9 Hide deprecated projects in sharing tab by default
Signed-off-by: Christopher Ng <chrng8@gmail.com>
2022-08-18 01:50:37 +07:00
Ferdinand Thiessen 1da424595f Feature: Add and expose frontend loglevel
This adds a new config variable `loglevel_frontend`,
allowing to configure the logging level of the
browser part as requested in nextcloud/nextcloud-logger#141

If not configured the `loglevel` is used as the fallback.

Signed-off-by: Ferdinand Thiessen <rpm@fthiessen.de>
2022-06-06 13:37:04 +07:00
Joas Schilling f9efc410fa
Restore old behaviour of sending flase for not found apps
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-05-30 12:41:35 +07:00
Joas Schilling eb1a69d627
Improve JSConfigHelper code quality a bit
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-05-30 12:33:45 +07:00
John Molakvoæ 9a9409e315
Remove SCSSCacher
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
2022-05-13 16:10:45 +07:00
John Molakvoæ 3c6253f965
Remove old legacy SvgController and IconsCacher
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
2022-05-10 23:24:07 +07:00
Carl Schwan 69b36fc2c5 Don't inject Bruteforce capability info in the webui
This capability do DB access and as far I know is not used by the webui.
This remove one DB query for each page load.

Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2022-04-07 17:33:29 +07:00
Côme Chilliet 1809386862
Fix codestyle
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-03-24 16:21:27 +07:00
Côme Chilliet 6be7aa112f
Migrate from ILogger to LoggerInterface in lib/private
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-03-24 16:21:25 +07:00
Julius Härtl e8cf1a8759
Avoid double-loading dist/core-main.js when apps have scripts named main
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-03-08 15:37:53 +07:00
Julius Härtl 55fd974926
Remove shortFooter/longFooter to avoid unnecessary navigation loading
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-01-12 12:16:39 +07:00
Louis Chemineau 6f62c17a95
Detect app's script higher up as some scripts were shadowed
Signed-off-by: Louis Chemineau <louis@chmn.me>
2022-01-08 10:15:48 +07:00
Louis Chemineau f8f09bff04
Restore some line in JSResourceLocator.php
Signed-off-by: Louis Chemineau <louis@chmn.me>
2022-01-08 10:11:58 +07:00
John Molakvoæ (skjnldsv) b664aad7ab
Move bundles to /dist
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2022-01-08 10:11:58 +07:00
Carl Schwan dfb569f097
Follow upstream security recommandation
See https://scssphp.github.io/scssphp/docs/#security-considerations

Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2021-12-02 15:57:53 +07:00
MichaIng 9189bc21fb Correct comment about OC_Defaults being used
Signed-off-by: MichaIng <micha@dietpi.com>
2021-11-15 18:44:02 +07:00
Carl Schwan df3d9107ef
Fix core depending on theming app
This was introduced in 309354852f
to fix a bug but I can't reproduce the bug after reverting this change.

Ideally we would need to create an interface in OCP and cleanup OC_Defaults
instead of depending on OC_Defaults.

Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2021-11-12 15:04:24 +07:00
Christopher Ng 309354852f Profile backend
Signed-off-by: Christopher Ng <chrng8@gmail.com>
2021-10-19 04:59:35 +07:00
Karel Hink 18cc6c11b5 Fix Lots of Error: file_exists(): open_basedir restriction in effect. in Log
Signed-off-by: Karel Hink <info@karelhink.cz>
2021-07-30 19:28:52 +07:00
Julius Härtl c0474ba364
Use product name in places where it is appropriate rather than the instance name
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-06-16 11:42:53 +07:00
John Molakvoæ (skjnldsv) 215aef3cbd
Update php licenses
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2021-06-04 22:02:41 +07:00
Joas Schilling 13b37a5255
Do not allow to overwrite some variables
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-27 13:55:35 +07:00
Vincent Petry af61486aea
Separate settings for remote share expiration
Added separate settings for default and enforced expiration date for
remote shares.

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-04-15 10:06:09 +07:00
Roeland Jago Douma 68ec18323d Fix types in the Group Manager
Psalm found an issue. However the issue found was because of lying
docblocks. Fixed those and did some typing to make it all better.

For #25839

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-03-03 14:52:47 +07:00
dependabot-preview[bot] eb502c02ff
Bump nextcloud/coding-standard from 0.3.0 to 0.5.0
Bumps [nextcloud/coding-standard](https://github.com/nextcloud/coding-standard) from 0.3.0 to 0.5.0.
- [Release notes](https://github.com/nextcloud/coding-standard/releases)
- [Changelog](https://github.com/nextcloud/coding-standard/blob/master/CHANGELOG.md)
- [Commits](https://github.com/nextcloud/coding-standard/compare/v0.3.0...v0.5.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-02-18 13:31:24 +07:00
Morris Jobke 5ed673e5eb
Merge pull request #25073 from nextcloud/psalm/24521/remove-unneeded-casts
Remove unneeded casts that were found by Psalm
2021-01-11 14:15:16 +07:00
Morris Jobke 24d436cb60
Remove unneeded casts that were found by Psalm
In preparation of the update of Psalm from 4.2.1 to 4.3.1+ (see https://github.com/nextcloud/server/pull/24521)

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2021-01-11 13:14:41 +07:00
Christoph Wurst c3cb288268
Bump scssphp/scssphp from 1.0.3 to 1.4.0
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-01-11 12:41:25 +07:00
Roeland Jago Douma ed1dcd3651
Set the JSCombiner cache if needed
Found while debugging a customer setup. They had to flush their Redis.
Hence the info was no longer there. Since they also used S3 this meant
requesting the files over and over on template render. Which on S3 is
not cheap.

Now we just write it back if we can't get it from the cache in the first
place. So that the next run has it cached properly again.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-01-06 16:15:17 +07:00
Christoph Wurst d89a75be0b
Update all license headers for Nextcloud 21
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-12-16 18:48:22 +07:00
Arthur Schiwon d8ad4ef6b5
use a consistent default value for sharing.maxAutocompleteResults
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-12-15 11:53:39 +07:00
Christoph Wurst 2526c5e042
Fix the config key on the sharing expire checkbox
We don't use `shareapi_internal_enforce_expire_date` anywhere.
`shareapi_enforce_internal_expire_date` is the one we want.

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-11-24 14:17:41 +07:00
Christoph Wurst 979b291a36
Show the full trace of an exception
Because often we catch the exception at some point and then the trace is
misleading. What's really interesting is the trace of the *previous*
exception.

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-11-10 10:35:08 +07:00
Roeland Jago Douma cd849db8be
Avoid SCSS compilation if not needed
Now we do on each template load a compile with the SCSS variables to see
if they changed or not. However there is no real reason for this if the
variables didn't change.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-11-06 11:31:36 +07:00
Morris Jobke 4bf891f605
Merge pull request #23478 from nextcloud/fix/21059/fix-deadlock-in-scsscacher
Clear cached app config while waiting for the SCSSCache lock to return
2020-10-16 14:56:43 +07:00