Skip to content

Commit 1d282a3

Browse files
committed
Fixing the bugfix pnp#1718
Bugfix pnp#1718 for bug pnp#1717 was faulty and gets fixed with this.
1 parent 64883f7 commit 1d282a3

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/controls/dynamicForm/DynamicForm.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -597,17 +597,17 @@ export class DynamicForm extends React.Component<
597597
hiddenName = response.value;
598598
termSetId = field.TermSetId;
599599
anchorId = field.AnchorId;
600-
if (item && item[field.InternalName] && item[field.InternalName].results) {
601-
item[field.InternalName].results.forEach((element) => {
600+
if (item && item[field.InternalName] && item[field.InternalName]) {
601+
item[field.InternalName].forEach((element) => {
602602
selectedTags.push({
603603
key: element.TermGuid,
604604
name: element.Label,
605605
});
606606
});
607607

608608
defaultValue = selectedTags;
609-
} else if (defaultValue && defaultValue.results) {
610-
defaultValue.results.forEach((element) => {
609+
} else if (defaultValue) {
610+
defaultValue.forEach((element) => {
611611
selectedTags.push({
612612
key: element.TermGuid,
613613
name: element.Label,

0 commit comments

Comments
 (0)