change to safe download, added imag convertion