Skip to content

Commit

Permalink
reorder functions
Browse files Browse the repository at this point in the history
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
  • Loading branch information
butonic committed Jun 3, 2022
1 parent 42a0265 commit 03bfdad
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -642,14 +642,14 @@ func isRename(s, d *provider.Reference) bool {
isShareJailRoot(d.ResourceId) && len(strings.SplitN(d.Path, "/", 3)) == 2
}

func isShareJailRoot(id *provider.ResourceId) bool {
func isShareJailChild(id *provider.ResourceId) bool {
_, space := storagespace.SplitStorageID(id.StorageId)
return space == utils.ShareStorageProviderID && id.OpaqueId == utils.ShareStorageProviderID
return space == utils.ShareStorageProviderID && id.OpaqueId != utils.ShareStorageProviderID
}

func isShareJailChild(id *provider.ResourceId) bool {
func isShareJailRoot(id *provider.ResourceId) bool {
_, space := storagespace.SplitStorageID(id.StorageId)
return space == utils.ShareStorageProviderID && id.OpaqueId != utils.ShareStorageProviderID
return space == utils.ShareStorageProviderID && id.OpaqueId == utils.ShareStorageProviderID
}

// SetLock puts a lock on the given reference
Expand Down

0 comments on commit 03bfdad

Please sign in to comment.