Commit Graph

18057 Commits

Author SHA1 Message Date
Roeland Jago Douma b57019bcaa
Log the route not found exception on a lower level
This should be logged but it is not that critical to wanner level 3

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-07-24 15:39:53 +02:00
Morris Jobke 15561b4e0a
Merge pull request #21977 from onehappycat/issue_21960
Ignore whitespace in sharing by mail
2020-07-24 13:37:36 +02:00
Julius Härtl e1b696929f
Move NotFoundResponse to a proper TemplateResponse
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-07-24 08:58:14 +02:00
Nextcloud bot c4a6666e6c
[tx-robot] updated from transifex 2020-07-24 02:16:52 +00:00
onehappycat e04525c186 Ignore whitespace in sharing by mail
Signed-off-by: onehappycat <one.happy.cat@gmx.com>
2020-07-23 22:20:18 +02:00
Morris Jobke ce314d9484
Merge pull request #21814 from nextcloud/techdebt/noid/federated_share_added-into-typed-event
Move federated_share_added into a typed event
2020-07-23 21:42:48 +02:00
Morris Jobke 173f8abc7e
Merge pull request #21628 from nextcloud/external-to-s3-trashbin-fix
fix moving files from external storage to object store trashbin
2020-07-23 21:35:18 +02:00
Robin Appelman c8cf2e8a5b
fix renameFromStorage messing with folder mimetype
Signed-off-by: Robin Appelman <robin@icewind.nl>
2020-07-23 20:31:35 +02:00
Simon Spannagel 1fc54d3479 Fix header logo size in notification mails
Signed-off-by: Simon Spannagel <simonspa@kth.se>
2020-07-23 17:52:21 +02:00
Robin Appelman ad7798f9c9
use exceptions for error signaling in writeStream
this remove the ambiguity when writing zero length files

Signed-off-by: Robin Appelman <robin@icewind.nl>
2020-07-23 15:24:52 +02:00
Robin Appelman 5949849322
fix moving files from external storage to object store trashbin
having the "cache rename" after the "storage move" caused the target
to get the fileid from the source file, without taking care that the object
is stored under the original file id.

By doing the "cache rename" first, we trigger the "update existing file"
logic while moving the file to the object store and the object gets stored for the
correct file id

Signed-off-by: Robin Appelman <robin@icewind.nl>
2020-07-23 15:24:44 +02:00
Roeland Jago Douma e0cc95f3aa
Allow user backends to specify a custom logout url
* Allows SSO backends to do a global logout

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-07-23 10:42:40 +02:00
Morris Jobke 0763a17332
Move federated_share_added into a typed event
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-07-23 08:33:17 +02:00
Nextcloud bot 99d0ba5f7e
[tx-robot] updated from transifex 2020-07-23 02:17:03 +00:00
Morris Jobke 346f647962
Merge pull request #21870 from nextcloud/fix/bootstrap-context-container-interfaces
Make the bootstrap context return ContainerInterface instances
2020-07-22 20:38:50 +02:00
Morris Jobke 7b250db60b
Merge pull request #21658 from nextcloud/trashbin-configurable-size
allow admin to configure the max trashbin size
2020-07-21 20:46:43 +02:00
Morris Jobke 7870ca0663
Use the proper IAppContainer and IServerContainer type hints to know which code runs with which container
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-07-21 20:44:05 +02:00
Christoph Wurst e029055e76
Make the bootstrap context return ContainerInterface instances
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-07-21 20:42:24 +02:00
Morris Jobke 09e6b26bdd
Merge pull request #21875 from nextcloud/techdebt/deprecate-ilogger
Deprecate ILogger in favor of the PSR-3 logger
2020-07-20 16:45:14 +02:00
Morris Jobke 9ae75a3ca9
Merge pull request #21850 from nextcloud/techdebt/noid/register-alternative-logins
Allow to register AlternativeLogin on RegistrationContext
2020-07-20 14:20:03 +02:00
Morris Jobke 9271d65641
Merge pull request #21880 from nextcloud/webauthn/discourage_user_auth
Discourage webauthn user interaction
2020-07-20 09:24:08 +02:00
Morris Jobke a1a1349977
Merge pull request #21891 from nextcloud/techdebt/undeprecate-iappcontainer-iservercontainer
Undeprecate IAppContainer and IServerContainer
2020-07-19 22:16:59 +02:00
Nextcloud bot d925c45373
[tx-robot] updated from transifex 2020-07-19 02:17:06 +00:00
Christoph Wurst 22ff03969e
Undeprecate IAppContainer and IServerContainer
With 4152216bd8 these two interfaces got
deprecated with the reasoning that we only need the base PSR interface.
However, there are cases where in Nextcloud you still want to have a
specific container (the one for the app vs the one for the server) when
you either have a container injected or query one from a container.

With a single interface that would not be possible. So it's probably
better if we leave the two interfaces, but only have them extend the PSR
interface. IContainer – with the custom methods – shall still be phased
out, but the two other sub interfaces can stay for tagging purposes.
Tagging means that no methods shall be added.

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-07-17 10:17:18 +02:00
Christoph Wurst 9bc6a8437d
Deprecate the query mothod on the server container
The interface method has already been deprecated, but if some code uses
the concrete type instead, the deprecation is not shown (by phpstorm),
so I think it's better to have this method tagged as well.

The "fix" for this deprecation is to simply use `get` instead of
`query`. Right now this will work 100% the same, but the goal is to slim
down the interface and only use what PSR-11 offers.

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-07-17 08:05:07 +02:00
Nextcloud bot 2c79083f27
[tx-robot] updated from transifex 2020-07-17 02:17:12 +00:00
Joas Schilling cae849bcf9
Merge pull request #21869 from nextcloud/techdebt/noid/add-constants-for-magic-strings
Add constants for the magic strings of template rendering
2020-07-16 22:00:57 +02:00
Roeland Jago Douma 884f3d009a
Discourage webauthn user interaction
Else people might have the feeling this is also doing 2FA. And since it
is only prefered it can be ignored and hacked around.

Once we have proper 2FA with webauthn in one go this probably needs to
be revisted.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-07-16 21:10:07 +02:00
Roeland Jago Douma dfcb49b9b7
Merge pull request #21873 from nextcloud/techdebt/deprecate-server-container-getters
Deprecate the server container getters
2020-07-16 20:27:36 +02:00
Christoph Wurst 8a433a7226
Deprecate ILogger
The logger service was always intended to follow the PSR-3 interface.
It's time to embrace this and switch over to the "official" API,
hence this custom interface can be slowly phased out.

With Nextcloud 20 the logger also got support for
* App id filled out automatically
* Exceptions handling (as replacement for logException)

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-07-16 19:19:23 +02:00
Christoph Wurst c889021334
Add a scoped PSR logger for apps
Just like for ILogger we should have a version that has the app ID
pre-set for the context (unless overwritten) so that each log entry can
be traced back to the app that produced it.

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-07-16 19:11:56 +02:00
Christoph Wurst efd2835b23
Deprecate the server container getters
Service locators are an anti pattern. These getters just make it more
appealing to do the wrong thing. If you want to locate a service the bad
way, just use the `get` method on a container – it will do the same in
also one line of code.

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-07-16 18:59:56 +02:00
Joas Schilling 49970639fa
Add constants for the magic strings of template rendering
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-07-16 15:47:28 +02:00
Joas Schilling 0dfcc132ca
Allow to register AlternativeLogin on RegistrationContext
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-07-16 14:20:24 +02:00
Christoph Wurst 4152216bd8
Use PSR container interface and deprecate our own abstraction
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-07-16 13:35:45 +02:00
Nextcloud bot 89fe5415f8
[tx-robot] updated from transifex 2020-07-16 02:19:30 +00:00
Morris Jobke c4b53538af
Better event description for BeforeTemplateRenderedEvent in files and files_sharing
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-07-15 20:15:51 +02:00
Morris Jobke fc41810d2f
Merge pull request #21822 from nextcloud/enh/events/additionalscripts
Add real events to load additionalscripts
2020-07-15 19:50:01 +02:00
Morris Jobke cc258ad51a
Merge pull request #21844 from bladewing/bladewing-harden-against-mimetype-mismatch
Avoid substr() error when strpos returns false
2020-07-15 19:33:09 +02:00
Roeland Jago Douma 7d7ba61625
Add real events to load additionalscripts
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-07-15 14:07:18 +02:00
Christoph Wurst b9a911f0b3
Deprecate the internal Symfony dispatcher adapter
This type is not known on the public API, yet we should make sure that
any usage of this class is noticed and migrated as soon as possible.

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-07-15 13:57:35 +02:00
lui87kw 3fe3d1fca3 Extra white space to follow other ifs
Signed-off-by: lui87kw <lukas.ifflaender@uni-wuerzburg.de>
2020-07-15 10:18:47 +02:00
bladewing 7dafd5831f Avoid substr() error when strpos returns false
"Exception: substr() expects parameter 3 to be int, bool given" can occur on Line 378 $mimePart = substr($icon, 0, strpos($icon, '-'));
This happens, when '-' is not found and strpos returns false instead of an int.
When this occurs, e.g., Activity hangs.

Signed-off-by: lui87kw <lukas.ifflaender@uni-wuerzburg.de>
2020-07-15 10:18:47 +02:00
Julius Härtl 35bdb998ef
Dashboard strict typing
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-07-15 09:28:12 +02:00
Julius Härtl 31a1494529
Add load method for apps to bootstrap their panels
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-07-15 09:28:11 +02:00
Julius Härtl b71de68f43
Cleanup public api methods
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-07-15 09:28:11 +02:00
Julius Härtl f7c04b0415
Deprecate panel register event right away but keep it for not breaking backward compatible apps
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-07-15 09:28:11 +02:00
Julius Härtl 81e5593133
Move to lazy panel registration during registration context
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-07-15 09:27:57 +02:00
Julius Härtl 86a7d1641a
Update autoloader
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-07-15 09:24:52 +02:00
Julius Härtl 544fcdb549
Deprecate old dashboard API
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-07-15 09:24:51 +02:00