Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
551eb6d2
Commit
551eb6d2
authored
Jul 10, 2014
by
David Lawrence
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 1036225: Return a link to the REST documentation in "method not found" errors
r=glob,a=glob
parent
8dbd57d5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
0 deletions
+6
-0
Constants.pm
Bugzilla/Constants.pm
+5
-0
REST.pm
Bugzilla/WebService/Server/REST.pm
+1
-0
No files found.
Bugzilla/Constants.pm
View file @
551eb6d2
...
...
@@ -18,6 +18,7 @@ use Memoize;
@
Bugzilla::Constants::
EXPORT
=
qw(
BUGZILLA_VERSION
REST_DOC
REMOTE_FILE
LOCAL_FILE
...
...
@@ -198,6 +199,10 @@ use Memoize;
# Bugzilla version
use
constant
BUGZILLA_VERSION
=>
"4.5.4+"
;
# A base link to the current REST Documentation. We place it here
# as it will need to be updated to whatever the current release is.
use
constant
REST_DOC
=>
"http://www.bugzilla.org/docs/tip/en/html/api/"
;
# Location of the remote and local XML files to track new releases.
use
constant
REMOTE_FILE
=>
'http://updates.bugzilla.org/bugzilla-update.xml'
;
use
constant
LOCAL_FILE
=>
'bugzilla-update.xml'
;
# Relative to datadir.
...
...
Bugzilla/WebService/Server/REST.pm
View file @
551eb6d2
...
...
@@ -120,6 +120,7 @@ sub response {
if
(
exists
$json_data
->
{
error
})
{
$result
=
$json_data
->
{
error
};
$result
->
{
error
}
=
$self
->
type
(
'boolean'
,
1
);
$result
->
{
documentation
}
=
REST_DOC
;
delete
$result
->
{
'name'
};
# Remove JSONRPCError
}
elsif
(
exists
$json_data
->
{
result
})
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment