Generate download link bugfix