Prettify handling of userAgent a bit