From cff1e4fc3596943db63603c614eb08945130eeaa Mon Sep 17 00:00:00 2001 From: Marius Peter Date: Wed, 1 Jan 2025 18:02:43 +0100 Subject: =?UTF-8?q?Rubocop=20=F0=9F=91=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/scores_controller.rb | 2 +- app/models/score.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'app') diff --git a/app/controllers/scores_controller.rb b/app/controllers/scores_controller.rb index 8754b91..7c46165 100644 --- a/app/controllers/scores_controller.rb +++ b/app/controllers/scores_controller.rb @@ -1,6 +1,6 @@ class ScoresController < ApplicationController allow_unauthenticated_access - before_action :set_tartiflette, only: [:new, :create, :edit_all, :update_all] + before_action :set_tartiflette, only: [ :new, :create, :edit_all, :update_all ] def new end diff --git a/app/models/score.rb b/app/models/score.rb index ccc795f..efbfee1 100644 --- a/app/models/score.rb +++ b/app/models/score.rb @@ -5,7 +5,7 @@ class Score < ApplicationRecord validates :value, presence: true, inclusion: { in: 1..5 } validates :session_id, presence: true validates :tartiflette_id, uniqueness: { - scope: [:scoring_criterium_id, :session_id], + scope: [ :scoring_criterium_id, :session_id ], message: "has already been scored for this session and criterium." } end -- cgit v1.2.3