Do not setup a session when not required on WebDAV requests
If basic auth is used on WebDAV endpoints, we will not setup a session
by default but instead set a test cookie. Clients which handle session
cookies properly will send back the cookie then on the second request
and a session will be initialized which can be resued for
authentication.
Signed-off-by: Julius Härtl <jus@bitgrid.net>
The tooltip of the initial quota display showed the usage percenteage
and the total available space. However, the total available space was
redundant, as it was shown just below. The tooltip of the updated quota
display showed the usage percenteage, but based on the quota rather than
the total available space, so there was a mismatch between the tooltip
and the bar below. Now the tooltip of the initial and the updated quota
display both show just the usage percenteage based on the total
available space.
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
Use total available space rather than quota when updating the display
The initial quota display uses the total available space rather than the
quota. Moreover, the relative usage is based on the total space rather
than the quota. Due to this now the total available space is also used
when updating the quota display.
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
Many users are getting confused by the inaccurate error message "Home storage for user $user not writable" because the storage *is* writable. The actual issue is a missing files/ subdirectory. cf. https://help.nextcloud.com/t/home-storage-for-user-not-writable/10831/7
By mentioning the possible cause in the error message, users are going to be able to rapidly solve their problem rather than bang their heads against the screen, Google, and eventually forums to find out that the error message is wrong in their case.
Yes, it would be better to detect and precisely describe the fault, or fix the problem automatically, but until then, be kind to the users for the next however many years.
Currently we are redirecting from ?dir=/&fileid=2 to ?dir=/. This is an
issue because we then need to load two pages with full file system setup
and authentification instead of one and the assets won't start loading
until the second page is delivered to the user.
Additionally when loading ?dir=/, we then change the url back to
?dir=/&fileid=2 (without reload) so that the next time we load the page
again we do the same thing again.
Depending on the speed of the server and internet connection we can save
100ms to 400ms, improving the user experience.
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
Since mails and notifications are only available for actions of other users
it does not make sense to allow changing this.
It also prevents the common misunderstanding with
"file was changed inside a favorited folder"
Signed-off-by: Joas Schilling <coding@schilljs.com>
Fix path handling when transferring incoming shares
When transferring incoming shares from a guest user without specifying a
path, the $path is empty.
The fix properly handles that situation to avoid looking for shares in a
path with doubled slashes which failed to find shares to transfer.
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
Since mails and notifications are only available for actions of other users
it does not make sense to allow changing this.
It also prevents the common misunderstanding with
"file was changed inside a favorited folder"
Signed-off-by: Joas Schilling <coding@schilljs.com>
Init user's file system if not existing on ownership transfer
This makes it a bit easier to transfer ownership when the new user
hasn't already logged in. This still doesn't support encrypted
storages because the keys are not generated yet.
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
The encoding check for file names is now happening the Scanner, and an
event will be emitted only if the storage doesn't contain the encoding
compatibility wrapper.
The event is listened to by the occ scan command to be able to display a
warning in case of file name mismatches when they have NFD encoding.
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
Whenever a user was deleted but is still recipient of share entries,
delete these entries upon transfer.
Usually such entries would disappear after running cleanup background
jobs.
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
Added support for transfering incoming file shares.
- new option --transfer-incoming-shares=1 | 0
- new config.php option 'transfer-incoming-shares' => true | false
The command line option overrules the config.php option.
Signed-off-by: Vincent Petry <vincent@nextcloud.com>