fix scripts patch