repaired scripts