From 67de7ac8c026bebd8d130352e48fd900b79160b0 Mon Sep 17 00:00:00 2001 From: Sjoerd Andringa Date: Mon, 30 Oct 2023 16:36:18 +0100 Subject: [PATCH] Add inline docs for #handle_invalid_record --- .../scimitar/active_record_backed_resources_controller.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/controllers/scimitar/active_record_backed_resources_controller.rb b/app/controllers/scimitar/active_record_backed_resources_controller.rb index a4fd306..db3363a 100644 --- a/app/controllers/scimitar/active_record_backed_resources_controller.rb +++ b/app/controllers/scimitar/active_record_backed_resources_controller.rb @@ -177,6 +177,10 @@ def save!(record, &block) handle_invalid_record(exception.record) end + # Deal with validation errors by responding with an appropriate SCIM error. + # + # +record+:: The record with validation errors. + # def handle_invalid_record(record) joined_errors = record.errors.full_messages.join('; ')