Skip to content

Commit c4d29fa

Browse files
committed
[#378] Make viewing forms in storybook more robust
1 parent 68c3165 commit c4d29fa

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/model/FormGenerator.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,11 @@ export default class FormGenerator {
3333
let formProperties;
3434
let form;
3535
return jsonld
36-
.flatten(structure, {})
37-
.then((flattenedStructure) => {
36+
.compact(structure, {})
37+
.then((compactedStructure) => {
3838
try {
3939
const [formQuestions, rootForm] =
40-
FormGenerator._constructFormQuestions(flattenedStructure, intl);
40+
FormGenerator._constructFormQuestions(compactedStructure, intl);
4141
form = rootForm;
4242
formProperties = {
4343
formQuestions,

0 commit comments

Comments
 (0)