#1204 fixed

https://github.com/CartoDB/cartodb/issues/1204
That logic is a bit brainfuck if you try to read it (even if is correct)... I prefer something more easily readable...