Skip to content
This repository has been archived by the owner on Aug 29, 2018. It is now read-only.

Bug 994174 - rhc not displaying CLIENT_MESSAGE returned by broker #442

Conversation

jwforres
Copy link
Member

No description provided.

@@ -466,11 +466,27 @@ def parse_response(response)

# Copy messages to each object
messages = Array(result['messages']).map do |m|
m['text'] if (m['field'] == 'result' || m['severity'] == 'result') && (m['severity'] != 'debug' || debug?)
m['text'] unless ((((m['field'] != 'result' && m['severity'] == 'info') || m['severity'] == 'debug') && !debug?) || m['severity'] == 'warning')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

switch this to a case statement in a .select instead:

.select do |m|
  severity, field = m.values_at('severity', 'field')
  switch
  case field == 'result'
     true
end.map{ |m| m['text'].chomp }

The logic is too compact now

@smarterclayton
Copy link
Contributor

Reviewed, [merge]

@openshift-bot
Copy link

Online Merge Results: SUCCESS (https://ci.dev.openshift.redhat.com/jenkins/job/test_pull_requests/4040/) (Image: devenv_3683)

@openshift-bot
Copy link

[Test]ing while waiting on the merge queue

@openshift-bot
Copy link

@openshift-bot
Copy link

Evaluated for online up to 28541a0

@openshift-bot
Copy link

Origin Test Results: Waiting for stable build of 'origin_ami'

openshift-bot pushed a commit that referenced this pull request Aug 21, 2013
@openshift-bot openshift-bot merged commit 5f99832 into openshift:master Aug 21, 2013
@jwforres jwforres deleted the bug_994174_rhc_client_messages_not_displayed branch November 25, 2013 14:29
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants