File tree Expand file tree Collapse file tree 1 file changed +5
-0
lines changed
src/com/magento/idea/magento2plugin/indexes Expand file tree Collapse file tree 1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change 5
5
6
6
package com .magento .idea .magento2plugin .indexes ;
7
7
8
+ import com .intellij .openapi .project .DumbService ;
8
9
import com .intellij .openapi .project .Project ;
9
10
import com .intellij .openapi .vfs .VfsUtilCore ;
10
11
import com .intellij .openapi .vfs .VirtualFile ;
@@ -118,8 +119,12 @@ private List<String> getNames(
118
119
* @return PsiDirectory
119
120
*/
120
121
public @ Nullable PsiDirectory getModuleDirectoryByModuleName (final String moduleName ) {
122
+ if (DumbService .getInstance (project ).isDumb ()) {
123
+ return null ;
124
+ }
121
125
final FileBasedIndex index = FileBasedIndex
122
126
.getInstance ();
127
+
123
128
final Collection <VirtualFile > files = index .getContainingFiles (
124
129
ModuleNameIndex .KEY ,
125
130
moduleName ,
You can’t perform that action at this time.
0 commit comments