FIX - downcase strings consistently (PR #10861)

ruby and postgres can treat certain characters differently when downcasing them. So do all the downcasing in ruby so that we get consistent results.

GitHub

Looks good and safe to me! merging.

:+1: