changed a global variable and introduced an error. WHOOPS