set up Brakeman and fix warnings