replacing and with && per rubocop