Skip to content

Commit 5aca566

Browse files
committed
Don't assume dataModel exists for model in isReadOnly #247
1 parent 265d330 commit 5aca566

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/groovy/au/org/ala/ecodata/forms/EditModelWidgetRenderer.groovy

+1-1
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ public class EditModelWidgetRenderer implements ModelWidgetRenderer {
138138
}
139139

140140
private static boolean isReadOnly(WidgetRenderContext context) {
141-
context.model.readonly || context.dataModel.computed
141+
context.model.readonly || context.dataModel?.computed
142142
}
143143
@Override
144144
void renderSelectMany(WidgetRenderContext context) {

0 commit comments

Comments
 (0)