Skip to content

Commit 1ab7b73

Browse files
committed
refactoring
1 parent 36866cb commit 1ab7b73

1 file changed

Lines changed: 6 additions & 5 deletions

File tree

  • packages/devextreme/js/__internal/core/utils

packages/devextreme/js/__internal/core/utils/m_data.ts

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -176,14 +176,15 @@ export const compileSetter = function (expr) {
176176
const lastLevelIndex = expr.length - 1;
177177
const unsafeFragment = expr.find(isUnsafePathFragment);
178178

179+
if (unsafeFragment !== undefined) {
180+
return function () {
181+
errors.log('E0123', unsafeFragment);
182+
};
183+
}
184+
179185
return function (obj, value, options) {
180186
options = prepareOptions(options);
181187

182-
if (unsafeFragment !== undefined) {
183-
errors.log('E0123', unsafeFragment);
184-
return;
185-
}
186-
187188
let currentValue = unwrap(obj, options);
188189

189190
expr.forEach(function (propertyName, levelIndex) {

0 commit comments

Comments
 (0)