Mercurial > public > sg101
changeset 287:47a7138fcccb
Fix typo in oembed/views.py. Added oembed provider fixture.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sat, 23 Oct 2010 20:42:45 +0000 (2010-10-23) |
parents | 72fd300685d5 |
children | 4ba879ccdc62 |
files | gpp/oembed/fixtures/providers.json gpp/oembed/views.py |
diffstat | 2 files changed, 13 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/gpp/oembed/fixtures/providers.json Sat Oct 23 20:42:45 2010 +0000 @@ -0,0 +1,12 @@ +[ + { + "pk": 1, + "model": "oembed.provider", + "fields": { + "api_endpoint": "http://www.youtube.com/oembed", + "name": "YouTube", + "url_regex": "^http://www\\.youtube\\.com/watch\\?v=\\S+$", + "format": 0 + } + } +] \ No newline at end of file
--- a/gpp/oembed/views.py Sat Oct 23 20:19:46 2010 +0000 +++ b/gpp/oembed/views.py Sat Oct 23 20:42:45 2010 +0000 @@ -62,7 +62,7 @@ return HttpResponse(json.dumps(data), content_type='application/json') - return HttpBadRequest("Sorry, we couldn't find that video.") + return HttpResponseBadRequest("Sorry, we couldn't find that video.") def fetch_saved_media(request):