NzbDrone/NzbDrone — pull request #81 by Taloth (2014-05-31 21:53:33+00:00)
Title: Search improvements

Several improvements related to search and import.
* Changed the sorting of the search results a bit to give the most likely match on top. (Levensthein algo)
* Search query for new series now permits tvdbid: or slug: prefix to add a specific series, which doesn't permit partial matches but at least allows us to add anything from trakt (H+ too via slug:hplus). Not sure what's the best way to hint to that capability, so for now it's a hidden feature. (trello 237)
* Previously only the video file parent dir was checked for _UNPACK_ prefix, which messes up badly for full season packs with subdirs. So now I check for the prefix for every folder all the way to the root.
* I had an indexer which backfilled its index, causing a huge (years) difference between the pubDate and the usenetdate resulting in drone fetching items well beyond the specified max retention. So I changed the code to use the usenetdate as publishDate if available with pubDate as backup.