Skip to content

Commit 43d63e2

Browse files
committed
943: added integration enabled check for custom search scope
1 parent b19b7f5 commit 43d63e2

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/com/magento/idea/magento2plugin/lang/psi/search/MagentoSearchScopesProvider.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
import com.intellij.openapi.util.NlsContexts;
1111
import com.intellij.psi.search.SearchScope;
1212
import com.intellij.psi.search.SearchScopeProvider;
13+
import com.magento.idea.magento2plugin.project.Settings;
1314
import java.util.Collections;
1415
import java.util.List;
1516
import org.jetbrains.annotations.NotNull;
@@ -27,6 +28,10 @@ public class MagentoSearchScopesProvider implements SearchScopeProvider {
2728
final @NotNull Project project,
2829
final @NotNull DataContext dataContext
2930
) {
31+
if (!Settings.isEnabled(project)) {
32+
return Collections.emptyList();
33+
}
34+
3035
return Collections.singletonList(AllFilesExceptTestsScope.getInstance(project));
3136
}
3237
}

0 commit comments

Comments
 (0)