var message = ""
if (XMLHttpRequest.responseText.length > 0)
  message = jQuery.parseJSON(XMLHttpRequest.responseText).error
...

JavaScript Double 'if'

by AlekSi, August 23, 2010 14:32, 9 refactorings, tagged with if

How to make this code looks...

Af19cd0c0141bf7d6b42516706eb1d1d Talk
hash = {}
array.each { |key| hash[key] = func(key) }

Ruby How to make it more idiomatic?

by AlekSi, August 16, 2010 11:58, 6 refactorings, tagged with ruby, idiomatic, idioms

Can you make this code more...

Af19cd0c0141bf7d6b42516706eb1d1d Talk