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
28498e1a
Commit
28498e1a
authored
12 years ago
by
Tom Needham
Browse files
Options
Downloads
Patches
Plain Diff
Code style and remove OAuth code
parent
e63c4e3e
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lib/api.php
+3
-11
3 additions, 11 deletions
lib/api.php
with
3 additions
and
11 deletions
lib/api.php
+
3
−
11
View file @
28498e1a
...
...
@@ -33,6 +33,7 @@ class OC_API {
const
USER_AUTH
=
1
;
const
SUBADMIN_AUTH
=
2
;
const
ADMIN_AUTH
=
3
;
/**
* API Response Codes
*/
...
...
@@ -40,15 +41,6 @@ class OC_API {
const
RESPOND_SERVER_ERROR
=
996
;
const
RESPOND_NOT_FOUND
=
998
;
const
RESPOND_UNKNOWN_ERROR
=
999
;
private
static
$server
;
/**
* initialises the OAuth store and server
*/
private
static
function
init
()
{
self
::
$server
=
new
OC_OAuth_Server
(
new
OC_OAuth_Store
());
}
/**
* api actions
...
...
@@ -156,9 +148,9 @@ class OC_API {
}
}
// Remove any error responses if there is one shipped response that succeeded
if
(
!
empty
(
$shipped
[
'succeeded'
])){
if
(
!
empty
(
$shipped
[
'succeeded'
]))
{
$responses
=
array_merge
(
$shipped
[
'succeeded'
],
$thirdparty
[
'succeeded'
]);
}
else
if
(
!
empty
(
$shipped
[
'failed'
])){
}
else
if
(
!
empty
(
$shipped
[
'failed'
]))
{
// Which shipped response do we use if they all failed?
// They may have failed for different reasons (different status codes)
// Which reponse code should we return?
...
...
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