From 6da3cb5498c836bcf8fa8dc0ea97398a660ecb70 Mon Sep 17 00:00:00 2001 From: blond Date: Fri, 10 Mar 2017 17:18:15 +0300 Subject: [PATCH] refactor(entities): use mod field for entities The `modName` and the `modVal` fields are deprecated. --- lib/walkers/nested.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/walkers/nested.js b/lib/walkers/nested.js index 3bfbdb2..0789d8e 100644 --- a/lib/walkers/nested.js +++ b/lib/walkers/nested.js @@ -141,7 +141,8 @@ class LevelWalker { const tech = item.tech; // Find file with same modifier name. - if (tech && entity && scope.block === entity.block && scope.modName === entity.modName) { + if (tech && entity && scope.block === entity.block + && scope.mod.name === (entity.mod && entity.mod.name)) { this.add(new BemFile( new BemCell({ entity: entity, @@ -212,7 +213,7 @@ class LevelWalker { if (tech && entity && scope.block === entity.block && scope.elem === entity.elem - && scope.modName === entity.modName + && scope.mod.name === (entity.mod && entity.mod.name) ) { this.add(new BemFile( new BemCell({