Fixed crashes on downloading