Skip to content

Commit 5798590

Browse files
authored
Merge pull request #2072 from Haehnchen/feature/property-filter
ignore prefix classnames for property import
2 parents d099e6c + eb19988 commit 5798590

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/main/java/fr/adrienbrault/idea/symfony2plugin/completion/IncompletePropertyServiceInjectionContributor.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,9 @@ public static List<String> getInjectionService(@NotNull Project project, @NotNul
324324
s = s.substring(i);
325325
}
326326

327-
return !s.endsWith("Test");
327+
return !s.endsWith("Test")
328+
&& !s.toLowerCase().contains("_phpstan_")
329+
&& !s.toLowerCase().contains("rectorprefix");
328330
}).collect(Collectors.toSet());
329331

330332
for (String fqn : collect) {
@@ -367,7 +369,7 @@ public static List<String> getInjectionService(@NotNull Project project, @NotNul
367369
if (fqn.toLowerCase().contains("\\contracts\\") && fqn.toLowerCase().contains("\\symfony\\")) {
368370
weight += 2;
369371
} else if(fqn.toLowerCase().contains("\\psr\\")) {
370-
weight += 2;
372+
weight += 3;
371373
}
372374
}
373375

0 commit comments

Comments
 (0)