Modified try block and added BAD_SCRIPTS