fixing bug in mirror init script