Apply Rails/Presence rubocop rule

This commit is contained in:
Javi Martín
2019-06-22 22:03:46 +02:00
parent adc5906253
commit a5ba13b599
13 changed files with 19 additions and 23 deletions

View File

@@ -37,7 +37,7 @@ class Polls::QuestionsController < ApplicationController
private
def load_for_answers
@page = params[:page].present? ? params[:page] : 1
@page = params[:page].presence || 1
question_answers
@answers_by_question_id = { @question.id => @question.answers
.by_author(current_user)