fix codeclimate issues