]> git.bitcoin.ninja Git - youtube-dl/commit
[YT Search] No results if items is not in response
authorJuan M <joksnet@gmail.com>
Tue, 26 Feb 2013 17:06:43 +0000 (18:06 +0100)
committerJuan M <joksnet@gmail.com>
Tue, 26 Feb 2013 17:06:43 +0000 (18:06 +0100)
commit9e07cf2955ce3fc7dc7c4676ec32da9bfd6e3990
treeeb70beeaf61ab413871989bdf2b38feb61236595
parentf03b88b3fb67a14998186787ba5c90f3e2c96a7b
[YT Search] No results if items is not in response

When a query results of 0 items, the key items is not present in the
api_response dictionary, raising a KeyError.

Intead, look for the key and call trouble if it's not present.
youtube_dl/InfoExtractors.py