def colorize_legacy_message(message)
      message.sub('MONGODB', color('MONGODB', odd? ? CYAN : MAGENTA)).
        sub(%r{(?<=\[')([^']+)}) {|m| color(m, BLUE)}.
        sub(%r{(?<=\]\.)\w+}) {|m| color(m, YELLOW)}
    end
def colorize_legacy_message(message)
      message.sub('MONGODB', color('MONGODB', odd? ? CYAN : MAGENTA)).
        sub(%r{(?<=\[')([^']+)}) {|m| color(m, BLUE)}.
        sub(%r{(?<=\]\.)\w+}) {|m| color(m, YELLOW)}
    end
Used for Mongoid < 3.0