Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-val
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-val
Commits
d04082c2
Commit
d04082c2
authored
Sep 26, 2014
by
Dave St.Germain
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #29 from edx/dcs/fix-youtube-lookup
Fixed youtube id lookup (no longer storing youtube urls in db)
parents
a3c54afe
16b84d3f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
3 deletions
+2
-3
edxval/models.py
+1
-2
edxval/tests/test_views.py
+1
-1
No files found.
edxval/models.py
View file @
d04082c2
...
...
@@ -93,10 +93,9 @@ class Video(models.Model):
"""
Look up video by youtube id
"""
url
=
'://youtu.be/
%
s'
%
youtube_id
qset
=
cls
.
objects
.
filter
(
encoded_videos__profile__profile_name
=
'youtube'
,
encoded_videos__url
__endswith
=
url
encoded_videos__url
=
youtube_id
)
.
prefetch_related
(
'encoded_videos'
,
'courses'
,
'subtitles'
)
return
qset
...
...
edxval/tests/test_views.py
View file @
d04082c2
...
...
@@ -516,7 +516,7 @@ class VideoListTest(APIAuthTestCase):
'encoded_videos'
:
[
{
'profile'
:
'youtube'
,
'url'
:
'
https://youtu.be/
AbcDef'
,
'url'
:
'AbcDef'
,
'file_size'
:
4545
,
'bitrate'
:
6767
,
}
...
...
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