mirror of
https://github.com/internetee/registry.git
synced 2025-08-06 01:35:10 +02:00
fixed legal attributes
This commit is contained in:
parent
ea2fc01a60
commit
86fad85d03
3 changed files with 29 additions and 22 deletions
|
@ -55,7 +55,10 @@ module Api
|
|||
attributes_not_exist_error(extra_attrs) and return if extra_attrs.present?
|
||||
end
|
||||
|
||||
# render_disclosed_attributes_error and return if disclosed_attributes.present? && contact.org?
|
||||
if disclosed_attributes.present? && contact.org?
|
||||
extra_attrs = disclosed_attributes - Contact::OPEN_LEGAL_ATTRIBUTES
|
||||
render_disclosed_attributes_error and return if extra_attrs.present?
|
||||
end
|
||||
|
||||
contact.disclosed_attributes = disclosed_attributes if disclosed_attributes
|
||||
publishable = reparsed_request[:registrant_publishable]
|
||||
|
|
|
@ -156,6 +156,10 @@ class Contact < ApplicationRecord
|
|||
fax
|
||||
].freeze
|
||||
|
||||
OPEN_LEGAL_ATTRIBUTES = %w[
|
||||
phone
|
||||
].freeze
|
||||
|
||||
STATUSES = [
|
||||
CLIENT_DELETE_PROHIBITED, SERVER_DELETE_PROHIBITED,
|
||||
CLIENT_TRANSFER_PROHIBITED,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue