fixed rubocop and foodcritic issues