1
0
مراية لـ https://github.com/postalserver/postal.git تم المزامنة 2025-12-01 05:43:04 +00:00

Fix removed ip_pool type errors (#62)

* Fix undefined method description

Sice `:description` was removed from the IP pools it should display the IP pool `:name` instead of the `:description`.

* Fix using the removed ip_pool type
هذا الالتزام موجود في:
Alex Bouma
2017-04-29 20:42:29 +02:00
ملتزم من قبل Adam Cooke
الأصل f779e45f45
التزام ddf2a859bf
2 ملفات معدلة مع 2 إضافات و2 حذوفات

عرض الملف

@@ -273,7 +273,7 @@ class Server < ApplicationRecord
end
def validate_ip_pool_belongs_to_organization
if self.ip_pool && self.ip_pool_id_changed? && (self.ip_pool.type == 'Dedicated' && !self.organization.ip_pools.include?(self.ip_pool))
if self.ip_pool && self.ip_pool_id_changed? && !self.organization.ip_pools.include?(self.ip_pool)
errors.add :ip_pool_id, "must belong to the organization"
end
end