Skip to content

Commit faa50a7

Browse files
committed
Quick fix for #2541
1 parent 758bbe0 commit faa50a7

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/com/goide/psi/impl/GoPsiImplUtil.java

+3-4
Original file line numberDiff line numberDiff line change
@@ -749,15 +749,14 @@ public void visitMethodSpec(@NotNull GoMethodSpec o) {
749749

750750
@NotNull
751751
public static List<GoMethodDeclaration> getMethods(@NotNull final GoTypeSpec o) {
752-
List<GoMethodDeclaration> result = CachedValuesManager.getCachedValue(o, new CachedValueProvider<List<GoMethodDeclaration>>() {
752+
return CachedValuesManager.getCachedValue(o, new CachedValueProvider<List<GoMethodDeclaration>>() {
753753
@Nullable
754754
@Override
755755
public Result<List<GoMethodDeclaration>> compute() {
756-
PsiDirectory packageDirectory = o.getContainingFile().getOriginalFile().getParent();
757-
return packageDirectory != null ? Result.create(calcMethods(o), packageDirectory) : null;
756+
// todo[zolotov]: implement package modification tracker
757+
return Result.create(calcMethods(o), PsiModificationTracker.MODIFICATION_COUNT);
758758
}
759759
});
760-
return result != null ? result : calcMethods(o);
761760
}
762761

763762
public static boolean allowed(@NotNull PsiFile declarationFile, @Nullable PsiFile referenceFile, @Nullable Module contextModule) {

0 commit comments

Comments
 (0)