Format messages as key/value pairs when passed a hash