fix script order