why create a temp var here? maybe you can just use `parsedUrl.Scheme`?