Merge pull request #2374 from openSUSE/depfu/update/shoulda-matchers-4.0.1

Update shoulda-matchers: 3.1.2 → 4.0.1 (major)
This commit is contained in:
Ana María Martínez Gómez 2019-06-03 09:23:52 +02:00 committed by GitHub
commit 47ce659a2f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View file

@ -31,7 +31,7 @@ class Registration < ApplicationRecord
validate :registration_to_events_only_if_present
validates :accepted_code_of_conduct, acceptance: {
if: -> { conference.code_of_conduct.present? }
if: -> { conference.try(:code_of_conduct).present? }
}
after_create :set_week, :subscribe_to_conference, :send_registration_mail