Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
our_own_cloud_project
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
die_coolen_jungs
our_own_cloud_project
Commits
2ef2dc4d
Commit
2ef2dc4d
authored
12 years ago
by
Bart Visscher
Browse files
Options
Downloads
Patches
Plain Diff
Fix "There must be a single space between the closing parenthesis and the opening brace"
parent
85bd28c5
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
apps/files_sharing/public.php
+1
-1
1 addition, 1 deletion
apps/files_sharing/public.php
lib/filecache.php
+3
-3
3 additions, 3 deletions
lib/filecache.php
lib/request.php
+2
-2
2 additions, 2 deletions
lib/request.php
settings/ajax/togglegroups.php
+1
-1
1 addition, 1 deletion
settings/ajax/togglegroups.php
with
7 additions
and
7 deletions
apps/files_sharing/public.php
+
1
−
1
View file @
2ef2dc4d
...
@@ -160,7 +160,7 @@ if ($linkItem) {
...
@@ -160,7 +160,7 @@ if ($linkItem) {
exit
();
exit
();
}
}
}
}
$basePath
=
substr
(
$pathAndUser
[
'path'
]
,
strlen
(
'/'
.
$fileOwner
.
'/files'
));
$basePath
=
substr
(
$pathAndUser
[
'path'
],
strlen
(
'/'
.
$fileOwner
.
'/files'
));
$path
=
$basePath
;
$path
=
$basePath
;
if
(
isset
(
$_GET
[
'path'
]))
{
if
(
isset
(
$_GET
[
'path'
]))
{
$path
.
=
$_GET
[
'path'
];
$path
.
=
$_GET
[
'path'
];
...
...
This diff is collapsed.
Click to expand it.
lib/filecache.php
+
3
−
3
View file @
2ef2dc4d
...
@@ -355,7 +355,7 @@ class OC_FileCache{
...
@@ -355,7 +355,7 @@ class OC_FileCache{
if
(
$sizeDiff
==
0
)
return
;
if
(
$sizeDiff
==
0
)
return
;
$item
=
OC_FileCache_Cached
::
get
(
$path
);
$item
=
OC_FileCache_Cached
::
get
(
$path
);
//stop walking up the filetree if we hit a non-folder or reached to root folder
//stop walking up the filetree if we hit a non-folder or reached to root folder
if
(
$path
==
'/'
||
$path
==
''
||
$item
[
'mimetype'
]
!==
'httpd/unix-directory'
){
if
(
$path
==
'/'
||
$path
==
''
||
$item
[
'mimetype'
]
!==
'httpd/unix-directory'
)
{
return
;
return
;
}
}
$id
=
$item
[
'id'
];
$id
=
$item
[
'id'
];
...
@@ -363,13 +363,13 @@ class OC_FileCache{
...
@@ -363,13 +363,13 @@ class OC_FileCache{
$query
=
OC_DB
::
prepare
(
'UPDATE `*PREFIX*fscache` SET `size`=`size`+? WHERE `id`=?'
);
$query
=
OC_DB
::
prepare
(
'UPDATE `*PREFIX*fscache` SET `size`=`size`+? WHERE `id`=?'
);
$query
->
execute
(
array
(
$sizeDiff
,
$id
));
$query
->
execute
(
array
(
$sizeDiff
,
$id
));
$path
=
dirname
(
$path
);
$path
=
dirname
(
$path
);
if
(
$path
==
''
or
$path
==
'/'
){
if
(
$path
==
''
or
$path
==
'/'
)
{
return
;
return
;
}
}
$parent
=
OC_FileCache_Cached
::
get
(
$path
);
$parent
=
OC_FileCache_Cached
::
get
(
$path
);
$id
=
$parent
[
'id'
];
$id
=
$parent
[
'id'
];
//stop walking up the filetree if we hit a non-folder
//stop walking up the filetree if we hit a non-folder
if
(
$parent
[
'mimetype'
]
!==
'httpd/unix-directory'
){
if
(
$parent
[
'mimetype'
]
!==
'httpd/unix-directory'
)
{
return
;
return
;
}
}
}
}
...
...
This diff is collapsed.
Click to expand it.
lib/request.php
+
2
−
2
View file @
2ef2dc4d
...
@@ -18,7 +18,7 @@ class OC_Request {
...
@@ -18,7 +18,7 @@ class OC_Request {
if
(
OC
::
$CLI
)
{
if
(
OC
::
$CLI
)
{
return
'localhost'
;
return
'localhost'
;
}
}
if
(
OC_Config
::
getValue
(
'overwritehost'
,
''
)
<>
''
){
if
(
OC_Config
::
getValue
(
'overwritehost'
,
''
)
<>
''
)
{
return
OC_Config
::
getValue
(
'overwritehost'
);
return
OC_Config
::
getValue
(
'overwritehost'
);
}
}
if
(
isset
(
$_SERVER
[
'HTTP_X_FORWARDED_HOST'
]))
{
if
(
isset
(
$_SERVER
[
'HTTP_X_FORWARDED_HOST'
]))
{
...
@@ -43,7 +43,7 @@ class OC_Request {
...
@@ -43,7 +43,7 @@ class OC_Request {
* Returns the server protocol. It respects reverse proxy servers and load balancers
* Returns the server protocol. It respects reverse proxy servers and load balancers
*/
*/
public
static
function
serverProtocol
()
{
public
static
function
serverProtocol
()
{
if
(
OC_Config
::
getValue
(
'overwriteprotocol'
,
''
)
<>
''
){
if
(
OC_Config
::
getValue
(
'overwriteprotocol'
,
''
)
<>
''
)
{
return
OC_Config
::
getValue
(
'overwriteprotocol'
);
return
OC_Config
::
getValue
(
'overwriteprotocol'
);
}
}
if
(
isset
(
$_SERVER
[
'HTTP_X_FORWARDED_PROTO'
]))
{
if
(
isset
(
$_SERVER
[
'HTTP_X_FORWARDED_PROTO'
]))
{
...
...
This diff is collapsed.
Click to expand it.
settings/ajax/togglegroups.php
+
1
−
1
View file @
2ef2dc4d
...
@@ -7,7 +7,7 @@ $success = true;
...
@@ -7,7 +7,7 @@ $success = true;
$username
=
$_POST
[
"username"
];
$username
=
$_POST
[
"username"
];
$group
=
$_POST
[
"group"
];
$group
=
$_POST
[
"group"
];
if
(
$username
==
OC_User
::
getUser
()
&&
$group
==
"admin"
&&
OC_Group
::
inGroup
(
$username
,
'admin'
)){
if
(
$username
==
OC_User
::
getUser
()
&&
$group
==
"admin"
&&
OC_Group
::
inGroup
(
$username
,
'admin'
))
{
$l
=
OC_L10N
::
get
(
'core'
);
$l
=
OC_L10N
::
get
(
'core'
);
OC_JSON
::
error
(
array
(
'data'
=>
array
(
'message'
=>
$l
->
t
(
'Admins can\'t remove themself from the admin group'
))));
OC_JSON
::
error
(
array
(
'data'
=>
array
(
'message'
=>
$l
->
t
(
'Admins can\'t remove themself from the admin group'
))));
exit
();
exit
();
...
...
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