Skip to content

Commit 36074fb

Browse files
author
Vitaliy
authored
Merge pull request #183 from magento/182-fix-null-pointer-excepiton-in-plugin-declaration-inspection
Fixed null pointer exception in the PluginDeclarationInspection
2 parents b5355fe + d455aff commit 36074fb

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/com/magento/idea/magento2plugin/inspections/xml/PluginDeclarationInspection.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,9 @@ public void visitFile(PsiFile file) {
9595
for (Pair<String, String> moduleEntry: modulesWithSamePluginName) {
9696
String scope = moduleEntry.getFirst();
9797
String moduleName = moduleEntry.getSecond();
98+
if (scope == null || moduleName == null) {
99+
continue;
100+
}
98101
String problemKey = pluginTypeKey.concat(Package.VENDOR_MODULE_NAME_SEPARATOR)
99102
.concat(moduleName).concat(Package.VENDOR_MODULE_NAME_SEPARATOR).concat(scope);
100103
if (!pluginProblems.containsKey(problemKey)){

0 commit comments

Comments
 (0)