Skip to content

Commit af076fe

Browse files
committed
Fix style
1 parent 088070a commit af076fe

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

app/messages/validators.rb

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -242,12 +242,9 @@ def validate(record)
242242

243243
class OptionsValidator < ActiveModel::Validator
244244
def validate(record)
245-
246245
if record.options.blank?
247246
# Route Creation with explicit 'null' options is not allowed
248-
if record.is_a?(VCAP::CloudController::RouteCreateMessage) && record.options.nil?
249-
record.errors.add(:options, message: 'is not a valid object')
250-
end
247+
record.errors.add(:options, message: 'is not a valid object') if record.is_a?(VCAP::CloudController::RouteCreateMessage) && record.options.nil?
251248
return
252249
end
253250

0 commit comments

Comments
 (0)