Move install file var under if block