Skip to content

Commit

Permalink
ShareAttributeRequestItemDVOs attribute.id is overridden with with …
Browse files Browse the repository at this point in the history
…`undefined` (#289)
  • Loading branch information
jkoenig134 authored Oct 2, 2024
1 parent 961b560 commit cdf5d46
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions packages/runtime/src/dataViews/DataViewExpander.ts
Original file line number Diff line number Diff line change
Expand Up @@ -660,11 +660,13 @@ export class DataViewExpander {
response: responseItemDVO
} as DecidableShareAttributeRequestItemDVO;
}
// We have to manually copy the attribute id here, otherwise we could not link to the local attribute
const shareAttributeResponseItem = responseItemDVO as ShareAttributeAcceptResponseItemDVO | undefined;
if (shareAttributeResponseItem) {
attributeDVO.id = shareAttributeResponseItem.attributeId;

if (responseItemDVO?.result === ResponseItemResult.Accepted) {
// We have to manually copy the attribute id here, otherwise we could not link to the local attribute
const shareAttributeResponseItem = responseItemDVO as ShareAttributeAcceptResponseItemDVO | undefined;
if (shareAttributeResponseItem) attributeDVO.id = shareAttributeResponseItem.attributeId;
}

return {
...shareAttributeRequestItem,
type: "ShareAttributeRequestItemDVO",
Expand Down

0 comments on commit cdf5d46

Please sign in to comment.