Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Nextcloud
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Monitor
Service Desk
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TeDomum
Nextcloud
Commits
bb2e68f7
Commit
bb2e68f7
authored
9 years ago
by
Thomas Müller
Browse files
Options
Downloads
Patches
Plain Diff
Fix chunk file move
parent
629bc181
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
apps/dav/lib/connector/sabre/filesplugin.php
+9
-1
9 additions, 1 deletion
apps/dav/lib/connector/sabre/filesplugin.php
with
9 additions
and
1 deletion
apps/dav/lib/connector/sabre/filesplugin.php
+
9
−
1
View file @
bb2e68f7
...
@@ -28,17 +28,19 @@
...
@@ -28,17 +28,19 @@
namespace
OCA\DAV\Connector\Sabre
;
namespace
OCA\DAV\Connector\Sabre
;
use
OC\Files\View
;
use
OC\Files\View
;
use
OCA\DAV\Upload\FutureFile
;
use
Sabre\DAV\Exception\Forbidden
;
use
Sabre\DAV\Exception\Forbidden
;
use
Sabre\DAV\Exception\NotFound
;
use
Sabre\DAV\Exception\NotFound
;
use
Sabre\DAV\IFile
;
use
Sabre\DAV\IFile
;
use
\Sabre\DAV\PropFind
;
use
\Sabre\DAV\PropFind
;
use
\Sabre\DAV\PropPatch
;
use
\Sabre\DAV\PropPatch
;
use
Sabre\DAV\ServerPlugin
;
use
Sabre\DAV\Tree
;
use
Sabre\DAV\Tree
;
use
\Sabre\HTTP\RequestInterface
;
use
\Sabre\HTTP\RequestInterface
;
use
\Sabre\HTTP\ResponseInterface
;
use
\Sabre\HTTP\ResponseInterface
;
use
OCP\Files\StorageNotAvailableException
;
use
OCP\Files\StorageNotAvailableException
;
class
FilesPlugin
extends
\Sabre\DAV\
ServerPlugin
{
class
FilesPlugin
extends
ServerPlugin
{
// namespace
// namespace
const
NS_OWNCLOUD
=
'http://owncloud.org/ns'
;
const
NS_OWNCLOUD
=
'http://owncloud.org/ns'
;
...
@@ -146,11 +148,17 @@ class FilesPlugin extends \Sabre\DAV\ServerPlugin {
...
@@ -146,11 +148,17 @@ class FilesPlugin extends \Sabre\DAV\ServerPlugin {
/**
/**
* Plugin that checks if a move can actually be performed.
* Plugin that checks if a move can actually be performed.
*
* @param string $source source path
* @param string $source source path
* @param string $destination destination path
* @param string $destination destination path
* @throws Forbidden
* @throws Forbidden
* @throws NotFound
*/
*/
function
checkMove
(
$source
,
$destination
)
{
function
checkMove
(
$source
,
$destination
)
{
$sourceNode
=
$this
->
server
->
tree
->
getNodeForPath
(
$source
);
if
(
$sourceNode
instanceof
FutureFile
)
{
return
;
}
list
(
$sourceDir
,)
=
\Sabre\HTTP\URLUtil
::
splitPath
(
$source
);
list
(
$sourceDir
,)
=
\Sabre\HTTP\URLUtil
::
splitPath
(
$source
);
list
(
$destinationDir
,)
=
\Sabre\HTTP\URLUtil
::
splitPath
(
$destination
);
list
(
$destinationDir
,)
=
\Sabre\HTTP\URLUtil
::
splitPath
(
$destination
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment