Côme Chilliet
c0ce272e9c
chore: Migrate away from OC::$server->getLogger
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
преди 3 месеца
Hamid Dehnavi
ea06cf2f39
Convert isset ternary to null coalescing operator
Signed-off-by: Hamid Dehnavi <hamid.dev.pro@gmail.com>
преди 11 месеца
John Molakvoæ (skjnldsv)
f828dce597
Fix sharing creation insert and get
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
преди 3 години
Faraz Samapoor
e7cc7653b8
Refactors "strpos" calls in lib/private to improve code readability.
Signed-off-by: Faraz Samapoor <fsamapoor@gmail.com>
преди 1 година
Arthur Schiwon
28e7235f87
hide shared files located in group folder's trash bin
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
преди 1 година
Côme Chilliet
f5c361cf44
composer run cs:fix
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
преди 1 година
Joas Schilling
99953a859b
Show group name instead of group id as recommendation
Signed-off-by: Joas Schilling <coding@schilljs.com>
преди 1 година
Carl Schwan
a1011bad6c
Use bigger slice in share provider
Probably won't make a big difference as it is unlikely a user has > 100
shares but this make sure we use the same code in spreed where the
change has a bigger impact.
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
преди 1 година
Carl Schwan
7b723813ce
Multiple fixes
- Fix tests
- Use non deprecated event stuff
- Add a bit of type hinting to the new stuff
- More safe handling of instanceOfStorage (share might not be the first
wrapper)
- Fix resharing
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
преди 1 година
Vincent Petry
bbb5043c07
Inherit hide download from share attributes
When resharing by link, if the download permission was removed through
share attributes, convert it to the hide download flag.
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
преди 2 години
Vincent Petry
dbbc426f75
Attempt to fix sqlite json issue
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
преди 2 години
Vincent Petry
a95c19e14b
Add share attributes + prevent download permission
Makes it possible to store download permission
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
преди 2 години
luz paz
368f83095d
Fix typos in lib/private subdirectory
Found via `codespell -q 3 -S l10n -L jus ./lib/private`
Signed-off-by: luz paz <luzpaz@github.com>
преди 1 година
Louis Chemineau
f525067930
Add argument to getSharesInFolder enable deep share lookup
Signed-off-by: Louis Chemineau <louis@chmn.me>
преди 1 година
Louis Chemineau
ce7b6ffed2
Prevent column name conflict between tables
Signed-off-by: Louis Chemineau <louis@chmn.me>
преди 2 години
Carl Schwan
81500bf837
Fix getting shares in a folder on Orache
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
преди 2 години
Robin Appelman
e83ad8cfad
fix shared mount roots not being returned from `getSharesInFolder`
Signed-off-by: Robin Appelman <robin@icewind.nl>
преди 2 години
Carl Schwan
6312c0df69
Check style update
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
преди 2 години
Julius Härtl
5116bf146f
Allow to pass note when creating a share and send it with directly in the share mail when set
Signed-off-by: Julius Härtl <jus@bitgrid.net>
преди 2 години
Côme Chilliet
ee7ef77808
Fix warning about passing null to substr_count
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
преди 2 години
John Molakvoæ (skjnldsv)
18f8fabd5a
Add proper message to created share not found
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
преди 3 години
John Molakvoæ (skjnldsv)
215aef3cbd
Update php licenses
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
преди 3 години
Arthur Schiwon
be3ae9a44b
gracefully handle deleteFromSelf when share is already gone
- handling race conditions
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
преди 3 години
Christoph Wurst
d89a75be0b
Update all license headers for Nextcloud 21
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
преди 3 години
Julius Härtl
d665981447
Only check path for being accessible when the storage is a object home
Signed-off-by: Julius Härtl <jus@bitgrid.net>
преди 3 години
Joas Schilling
cffad62771
Empty string is returned as null, but empty string in file cache is the root and exists
Signed-off-by: Joas Schilling <coding@schilljs.com>
преди 3 години
Arthur Schiwon
fd23614c08
fixes potential passing of null to getUserGroupIds
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
преди 3 години
Joas Schilling
db8267db26
Use the new method everywhere
Signed-off-by: Joas Schilling <coding@schilljs.com>
преди 4 години
Joas Schilling
89ed2c37bf
Update share type constant usage
Signed-off-by: Joas Schilling <coding@schilljs.com>
преди 4 години
Joas Schilling
95652d4469
Fix language in share notes email for users
Signed-off-by: Joas Schilling <coding@schilljs.com>
преди 4 години
Morris Jobke
e3a2d069ae
Remove unused use statement
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
преди 4 години
Robin Appelman
756fe45493
get only groupids in default share backend
instead of getting the full group object and then only using the id anyway
Signed-off-by: Robin Appelman <robin@icewind.nl>
преди 4 години
Christoph Wurst
28f8eb5dba
Add visibility to all constants
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
преди 4 години
Christoph Wurst
caff1023ea
Format control structures, classes, methods and function
To continue this formatting madness, here's a tiny patch that adds
unified formatting for control structures like if and loops as well as
classes, their methods and anonymous functions. This basically forces
the constructs to start on the same line. This is not exactly what PSR2
wants, but I think we can have a few exceptions with "our" style. The
starting of braces on the same line is pracrically standard for our
code.
This also removes and empty lines from method/function bodies at the
beginning and end.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
преди 4 години
Christoph Wurst
14c996d982
Use elseif instead of else if
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
преди 4 години
Christoph Wurst
afbd9c4e6e
Unify function spacing to PSR2 recommendation
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
преди 4 години
Christoph Wurst
2fbad1ed72
Fix (array) indent style to always use one tab
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
преди 4 години
Christoph Wurst
1a9330cd69
Update the license headers for Nextcloud 19
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
преди 4 години
Christoph Wurst
b80ebc9674
Use the short array syntax, everywhere
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
преди 4 години
Joas Schilling
51d174a40b
Also bail out when the path is actually null
Apparently this can happen when a external mount was shared
that is later not available anymore
Signed-off-by: Joas Schilling <coding@schilljs.com>
преди 4 години
Christoph Wurst
74936c49ea
Remove unused imports
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
преди 4 години
Joas Schilling
c5bc317681
Make sure the default share provider does not execute for other things
Signed-off-by: Joas Schilling <coding@schilljs.com>
преди 4 години
Christoph Wurst
5bf3d1bb38
Update license headers
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
преди 4 години
Roeland Jago Douma
21d7383d95
Allow internal shares to have a default expiration date
* Needs admin UI
* Needs more checks
* Basics seem to work
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
преди 4 години
Roeland Jago Douma
68748d4f85
Some php-cs fixes
* Order the imports
* No leading slash on imports
* Empty line before namespace
* One line per import
* Empty after imports
* Emmpty line at bottom of file
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
преди 4 години
Roeland Jago Douma
e16321368f
Fixes
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
преди 4 години
Joas Schilling
520042bbd0
Allow to accept group shares
Signed-off-by: Joas Schilling <coding@schilljs.com>
преди 4 години
Joas Schilling
e96c9e0e4a
Add the notifier and the API endpoint for user shares
Signed-off-by: Joas Schilling <coding@schilljs.com>
преди 4 години
Joas Schilling
dcdbea54e6
Respect the accepted flag for group and user shares
Signed-off-by: Joas Schilling <coding@schilljs.com>
преди 4 години
Roeland Jago Douma
8085ca4cc4
Get all shares as iterable
Sometimes we need all shares or rather a specific subset of shares but
creating dedicated functions is a pain. This just returns an iterable
object for all shares so we can loop over them without allocating all
the memory on the system.
It should not be used by any user called code. But in an occ command or
background job it is fine IMO.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
преди 4 години