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
dc60dd20
Commit
dc60dd20
authored
Nov 17, 2017
by
Bessie Steinberg
Committed by
Bill Filler
Nov 30, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
return descriptor instead of return non
parent
35859b65
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
lms/djangoapps/courseware/access.py
+1
-1
lms/djangoapps/courseware/module_render.py
+1
-1
No files found.
lms/djangoapps/courseware/access.py
View file @
dc60dd20
...
...
@@ -747,7 +747,7 @@ def _can_access_descriptor_with_milestones(user, descriptor, course_key):
"""
if
milestones_helpers
.
get_course_content_milestones
(
course_key
,
unicode
(
descriptor
.
location
),
'requires'
,
user
.
id
):
debug
(
"Deny: user has not completed all milestones for content"
)
return
ACCESS_DENIED
return
ACCESS_DENIED
#TODO: Tag descriptor with gated somehow
else
:
return
ACCESS_GRANTED
...
...
lms/djangoapps/courseware/module_render.py
View file @
dc60dd20
...
...
@@ -838,7 +838,7 @@ def get_module_for_descriptor_internal(user, descriptor, student_data, course_id
user_needs_access_check
=
getattr
(
user
,
'known'
,
True
)
and
not
isinstance
(
user
,
SystemUser
)
if
user_needs_access_check
:
if
not
has_access
(
user
,
'load'
,
descriptor
,
course_id
):
return
None
return
descriptor
#TODO: tag descriptor as needed to be gated
return
descriptor
...
...
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