fix script load ordering