fix some scripts