#1866: support gelbooru source redirection

doesn't support the discontinued sha1 naming scheme in some older files