Don't pretty-print by default. Saves an allocation (or more) and a copy.

This commit is contained in:
Brendan Burns
2015-06-08 16:33:58 -07:00
parent b68e08f55f
commit b68ddbaf75
8 changed files with 2603 additions and 19 deletions

View File

@@ -505,7 +505,7 @@ func UpdateResource(r rest.Updater, scope RequestScope, typer runtime.ObjectType
if wasCreated {
status = http.StatusCreated
}
writeJSON(status, scope.Codec, result, w)
writeJSON(status, scope.Codec, result, w, isPrettyPrint(req.Request))
}
}