fix scriptdir order