-
Notifications
You must be signed in to change notification settings - Fork 896
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Compare Current and Desired queue arrays #16325
Conversation
@miq-bot add_label bug |
I'll fix stopping Amazon refresh workers in a follow up PR. |
d489824
to
acfe2bb
Compare
@@ -114,6 +114,10 @@ def ems_id_from_queue_name(queue_name) | |||
def ems_from_queue_name(queue_name) | |||
ExtManagementSystem.find_by(:id => ems_id_from_queue_name(queue_name)) | |||
end | |||
|
|||
def compare_queues(current, desired) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be a private method?
Yes I made it a private method at first and it didn't work. Then after making it public I realised I had it in the wrong part of the file (was in the other module). Forgot then to privatise again.
… On 27 Oct 2017, at 17:38, Jason Frey ***@***.***> wrote:
@Fryguy commented on this pull request.
In app/models/mixins/per_ems_worker_mixin.rb:
> @@ -114,6 +114,10 @@ def ems_id_from_queue_name(queue_name)
def ems_from_queue_name(queue_name)
ExtManagementSystem.find_by(:id => ems_id_from_queue_name(queue_name))
end
+
+ def compare_queues(current, desired)
Should this be a private method?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
* Flatten & sort arrays * Compare values return boolean. Changed `if current != desired` to unless method as compare_queues returns a boolean.
acfe2bb
to
cb4b389
Compare
Checked commit juliancheal@cb4b389 with ruby 2.3.3, rubocop 0.47.1, and haml-lint 0.20.0 |
@Fryguy made the method |
Changed
if current != desired
tounless
method as compare_queuesreturns a boolean.