Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
python-bigbluebutton2
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
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
InfraBlue
python-bigbluebutton2
Commits
1dd5dd26
Verified
Commit
1dd5dd26
authored
4 years ago
by
Nik | Klampfradler
Browse files
Options
Downloads
Patches
Plain Diff
Return ping response when leaving out method name
parent
a50612f9
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
bigbluebutton/django/urls.py
+2
-1
2 additions, 1 deletion
bigbluebutton/django/urls.py
bigbluebutton/django/views.py
+2
-2
2 additions, 2 deletions
bigbluebutton/django/views.py
with
4 additions
and
3 deletions
bigbluebutton/django/urls.py
+
2
−
1
View file @
1dd5dd26
...
...
@@ -3,5 +3,6 @@ from django.urls import path
from
.views
import
APIView
urlpatterns
=
[
path
(
"
api/<str:method>
"
,
APIView
.
as_view
(),
name
=
"
api_request
"
),
path
(
"
api/<str:method>
"
,
APIView
.
as_view
()),
path
(
"
api
"
,
APIView
.
as_view
()),
]
This diff is collapsed.
Click to expand it.
bigbluebutton/django/views.py
+
2
−
2
View file @
1dd5dd26
...
...
@@ -18,7 +18,7 @@ class APIView(View):
# Set to False to mimic the reference implementation more closely
_fix_status
=
True
def
dispatch
(
self
,
request
:
HttpRequest
,
method
:
str
)
->
HttpResponse
:
def
dispatch
(
self
,
request
:
HttpRequest
,
method
:
str
=
"
ping
"
)
->
HttpResponse
:
# Find API tokens to allow for this request
site
=
get_current_site
(
request
)
api_tokens
=
APIToken
.
objects
.
filter
(
server_group__site
=
site
)
...
...
@@ -49,7 +49,7 @@ class APIView(View):
# Proprietary extension for test purposes
if
method
==
"
ping
"
:
return
self
.
_success
(
"
xInfraBluePong
"
,
"
The API is working correctly and your request was valid.
"
"
xInfraBluePong
"
,
"
The API is working correctly and your request was valid.
"
,
{
"
version
"
:
"
2.0
"
}
)
# Create mutable copy of request args without checksum
...
...
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