fixed a nasty download bug