1
0
mirror of https://github.com/OpenNebula/one.git synced 2024-12-22 13:33:52 +03:00

L #-: Disbale ConditionalAssignment check.

Fix provision.rb

(cherry picked from commit ca40d0f8db)
This commit is contained in:
Ruben S. Montero 2022-05-04 13:47:43 +02:00
parent 2216a9db7a
commit 09e7c9b587
No known key found for this signature in database
GPG Key ID: A0CEA6FA880A1D87
2 changed files with 8 additions and 6 deletions

View File

@ -579,7 +579,9 @@ Style/SignalException:
EnforcedStyle: only_raise
Style/ConditionalAssignment:
EnforcedStyle: assign_inside_condition
Enabled: false
# EnforcedStyle: assign_inside_condition
# EnforcedStyle: assign_to_condition
# No parentheses with no argument
Style/DefWithParentheses:

View File

@ -182,11 +182,11 @@ module OneProvision
def provider
return @provider if @provider
@provider = if @body['provider'] == 'onprem'
Provider.new_onprem(@client)
else
Provider.by_name(@client, @body['provider'])
end
@provider = if @body['provider'] == 'onprem'
Provider.new_onprem(@client)
else
Provider.by_name(@client, @body['provider'])
end
end
# Returns infrastructure + resource objects