File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -1122,10 +1122,6 @@ export default class SchemaController {
1122
1122
return Promise . resolve ( ) ;
1123
1123
} )
1124
1124
. then ( ( ) => {
1125
- const cached = SchemaCache . get ( className ) ;
1126
- if ( cached && ! cached . fields [ fieldName ] ) {
1127
- cached . fields [ fieldName ] = type ;
1128
- }
1129
1125
return {
1130
1126
className,
1131
1127
fieldName,
@@ -1251,6 +1247,10 @@ export default class SchemaController {
1251
1247
const enforceFields = results . filter ( result => ! ! result ) ;
1252
1248
1253
1249
if ( enforceFields . length !== 0 ) {
1250
+ const cached = SchemaCache . get ( className ) ;
1251
+ enforceFields . forEach ( ( { fieldName, type } ) => {
1252
+ cached . fields [ fieldName ] = type ;
1253
+ } ) ;
1254
1254
await this . reloadData ( ) ;
1255
1255
}
1256
1256
this . ensureFields ( enforceFields ) ;
You can’t perform that action at this time.
0 commit comments