fix brakeman issues