Python 3. Content-disposition check removed as it was incorrect.