Save and parse repository index when AddonManager loads

Meaning the user doesn't have to redownload it each time he starts the
game.
A first try at error handling in the Downloader

This isn't fully working, as skipping the .then() callbacks skips over
important cleanup and leads to failure further down the line.