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
bd8b3f52
Commit
bd8b3f52
authored
8 years ago
by
Lukas Reschke
Committed by
GitHub
8 years ago
Browse files
Options
Downloads
Plain Diff
Merge pull request #1830 from nextcloud/downstream-26250
Improved exception messages
parents
24786d5c
169faf8c
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
lib/private/Avatar.php
+1
-1
1 addition, 1 deletion
lib/private/Avatar.php
lib/private/Files/Node/Folder.php
+6
-6
6 additions, 6 deletions
lib/private/Files/Node/Folder.php
with
7 additions
and
7 deletions
lib/private/Avatar.php
+
1
−
1
View file @
bd8b3f52
...
...
@@ -131,7 +131,7 @@ class Avatar implements IAvatar {
}
if
(
!
(
$img
->
height
()
===
$img
->
width
()))
{
throw
new
NotSquareException
();
throw
new
NotSquareException
(
$this
->
l
->
t
(
"Avatar image is not square"
)
);
}
$this
->
remove
();
...
...
This diff is collapsed.
Click to expand it.
lib/private/Files/Node/Folder.php
+
6
−
6
View file @
bd8b3f52
...
...
@@ -42,7 +42,7 @@ class Folder extends Node implements \OCP\Files\Folder {
*/
public
function
getFullPath
(
$path
)
{
if
(
!
$this
->
isValidPath
(
$path
))
{
throw
new
NotPermittedException
();
throw
new
NotPermittedException
(
'Invalid path'
);
}
return
$this
->
path
.
$this
->
normalizePath
(
$path
);
}
...
...
@@ -152,7 +152,7 @@ class Folder extends Node implements \OCP\Files\Folder {
$this
->
root
->
emit
(
'\OC\Files'
,
'postCreate'
,
array
(
$node
));
return
$node
;
}
else
{
throw
new
NotPermittedException
();
throw
new
NotPermittedException
(
'No create permission for folder'
);
}
}
...
...
@@ -173,7 +173,7 @@ class Folder extends Node implements \OCP\Files\Folder {
$this
->
root
->
emit
(
'\OC\Files'
,
'postCreate'
,
array
(
$node
));
return
$node
;
}
else
{
throw
new
NotPermittedException
();
throw
new
NotPermittedException
(
'No create permission for path'
);
}
}
...
...
@@ -321,7 +321,7 @@ class Folder extends Node implements \OCP\Files\Folder {
$this
->
root
->
emit
(
'\OC\Files'
,
'postDelete'
,
array
(
$nonExisting
));
$this
->
exists
=
false
;
}
else
{
throw
new
NotPermittedException
();
throw
new
NotPermittedException
(
'No delete permission for path'
);
}
}
...
...
@@ -343,7 +343,7 @@ class Folder extends Node implements \OCP\Files\Folder {
$this
->
root
->
emit
(
'\OC\Files'
,
'postWrite'
,
array
(
$targetNode
));
return
$targetNode
;
}
else
{
throw
new
NotPermittedException
();
throw
new
NotPermittedException
(
'No permission to copy to path'
);
}
}
...
...
@@ -366,7 +366,7 @@ class Folder extends Node implements \OCP\Files\Folder {
$this
->
path
=
$targetPath
;
return
$targetNode
;
}
else
{
throw
new
NotPermittedException
();
throw
new
NotPermittedException
(
'No permission to move to path'
);
}
}
...
...
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