Skip to content

Commit 44ce14e

Browse files
committed
Check if schema is empty, if so do nothing
1 parent 9fdf2af commit 44ce14e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/directives/schema-form.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ function($compile, schemaForm, schemaFormDecorators){
7777
var form = scope.initialForm || ['*'];
7878

7979
//The check for schema.type is to ensure that schema is not {}
80-
if (form && schema && schema.type && (lastDigest.form !== form || lastDigest.schema !== schema)) {
80+
if (form && schema && schema.type && (lastDigest.form !== form || lastDigest.schema !== schema) && Object.keys(schema.properties).length > 0) {
8181
lastDigest.schema = schema;
8282
lastDigest.form = form;
8383

0 commit comments

Comments
 (0)