The added test explains the problem case, but basically any headers set on the initial HyperResource object were not being passed to embedded objects. (Link objects got the headers just fine.)
I hit this when passing an OAuth 2.0 bearer token. It worked fine for link resources, but I was getting 401 Unauthorized for any embedded resources.
The situation affects other client headers, like Content-Type.
The added test explains the problem case, but basically any headers set on the initial
HyperResource
object were not being passed to embedded objects. (Link objects got the headers just fine.)I hit this when passing an OAuth 2.0 bearer token. It worked fine for link resources, but I was getting
401 Unauthorized
for any embedded resources.The situation affects other client headers, like
Content-Type
.