Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
0ec2e643
Commit
0ec2e643
authored
Oct 23, 2014
by
Jonathan Piacenti
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
discussion-integration: Ignore query string when deriving course from URL.
parent
9dd21a04
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
common/djangoapps/util/request.py
+3
-0
No files found.
common/djangoapps/util/request.py
View file @
0ec2e643
...
@@ -42,6 +42,9 @@ def course_id_from_url(url):
...
@@ -42,6 +42,9 @@ def course_id_from_url(url):
if
'/'
in
url
:
if
'/'
in
url
:
deprecated
=
True
deprecated
=
True
# Ignore query string
url
=
url
.
split
(
'?'
)[
0
]
if
deprecated
:
if
deprecated
:
COURSE_REGEX
=
re
.
compile
(
r'^.*/courses/(?P<course_id>[^/]+/[^/]+/[^/]+)'
)
COURSE_REGEX
=
re
.
compile
(
r'^.*/courses/(?P<course_id>[^/]+/[^/]+/[^/]+)'
)
key_generator
=
SlashSeparatedCourseKey
.
from_deprecated_string
key_generator
=
SlashSeparatedCourseKey
.
from_deprecated_string
...
...
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