updated alloc_endpoint to mutate a copy of the returned allocation, instead of the instance in the state store

This commit is contained in:
Chris Baker 2020-11-15 17:52:50 +00:00
parent b244d5e949
commit 7c6071e6c4

View file

@ -127,6 +127,7 @@ func (s *HTTPServer) allocGet(allocID string, resp http.ResponseWriter, req *htt
alloc.SetEventDisplayMessages()
// Handle 0.12 ports upgrade path
alloc = alloc.Copy()
alloc.AllocatedResources.Canonicalize()
return alloc, nil