diff --git a/jael_preprocessor/lib/jael_preprocessor.dart b/jael_preprocessor/lib/jael_preprocessor.dart index 270d61dc..27d081d9 100644 --- a/jael_preprocessor/lib/jael_preprocessor.dart +++ b/jael_preprocessor/lib/jael_preprocessor.dart @@ -35,7 +35,7 @@ Future applyInheritance(Document document, Directory currentDirectory, var element = document.root; var attr = element.attributes - .firstWhere((a) => a.name.name == 'src', orElse: () => null); + .firstWhere((a) => a.name == 'src', orElse: () => null); if (attr == null) { onError(new JaelError(JaelErrorSeverity.warning, 'Missing "src" attribute in "extend" tag.', element.tagName.span)); @@ -91,7 +91,7 @@ Map extractBlockDeclarations( for (Element blockElement in blockElements) { var nameAttr = blockElement.attributes - .firstWhere((a) => a.name.name == 'name', orElse: () => null); + .firstWhere((a) => a.name == 'name', orElse: () => null); if (nameAttr == null) { onError(new JaelError(JaelErrorSeverity.warning, 'Missing "name" attribute in "block" tag.', blockElement.span)); @@ -115,7 +115,7 @@ String getParent(Document document, void onError(JaelError error)) { if (element.tagName.name != 'extend') return null; var attr = element.attributes - .firstWhere((a) => a.name.name == 'src', orElse: () => null); + .firstWhere((a) => a.name == 'src', orElse: () => null); if (attr == null) { onError(new JaelError(JaelErrorSeverity.warning, 'Missing "src" attribute in "extend" tag.', element.tagName.span)); @@ -150,7 +150,7 @@ Future expandBlocks(Element element, Map blocks, expanded.add(child); } else { var nameAttr = child.attributes - .firstWhere((a) => a.name.name == 'name', orElse: () => null); + .firstWhere((a) => a.name == 'name', orElse: () => null); if (nameAttr == null) { onError(new JaelError(JaelErrorSeverity.warning, 'Missing "name" attribute in "block" tag.', child.span)); @@ -243,7 +243,7 @@ Future _expandIncludes(Element element, Directory currentDirectory, } var attr = element.attributes - .firstWhere((a) => a.name.name == 'src', orElse: () => null); + .firstWhere((a) => a.name == 'src', orElse: () => null); if (attr == null) { onError(new JaelError(JaelErrorSeverity.warning, 'Missing "src" attribute in "include" tag.', element.tagName.span)); diff --git a/jael_preprocessor/pubspec.yaml b/jael_preprocessor/pubspec.yaml index 8325d939..d3c29ca0 100644 --- a/jael_preprocessor/pubspec.yaml +++ b/jael_preprocessor/pubspec.yaml @@ -1,5 +1,5 @@ name: jael_preprocessor -version: 1.0.0-alpha+1 +version: 1.0.0-alpha+2 description: A pre-processor for resolving blocks and includes within Jael templates. author: Tobe O homepage: https://github.com/angel-dart/jael/tree/master/jael_processor