mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-21 12:14:37 +07:00
EA-26528 - NPE: InplaceIntroduceFieldPopup$FieldInplaceIntroducer$3.run
This commit is contained in:
+2
-2
@@ -418,11 +418,11 @@ public class InplaceIntroduceConstantPopup {
|
||||
}
|
||||
}
|
||||
|
||||
if (myAnchorIdxIfAll != -1) {
|
||||
if (myAnchorIdxIfAll != -1 && myOccurrences[myAnchorIdxIfAll] != null) {
|
||||
myAnchorElementIfAll = myOccurrences[myAnchorIdxIfAll].getParent();
|
||||
}
|
||||
|
||||
if (myAnchorIdx != -1) {
|
||||
if (myAnchorIdx != -1 && myOccurrences[myAnchorIdx] != null) {
|
||||
myAnchorElement = myOccurrences[myAnchorIdx].getParent();
|
||||
}
|
||||
myOccurrenceMarkers = null;
|
||||
|
||||
+2
-2
@@ -335,8 +335,8 @@ public class InplaceIntroduceFieldPopup {
|
||||
final BaseExpressionToFieldHandler.ConvertToFieldRunnable convertToFieldRunnable =
|
||||
new BaseExpressionToFieldHandler.ConvertToFieldRunnable(myInitializerExpression, settings, settings.getForcedType(),
|
||||
myOccurrences, myOccurenceManager,
|
||||
myAnchorIdxIfAll != -1? myOccurrences[myAnchorIdxIfAll].getParent() : myAnchorElementIfAll,
|
||||
myAnchorIdx != -1 ? myOccurrences[myAnchorIdx].getParent() : myAnchorElement, myEditor,
|
||||
myAnchorIdxIfAll != -1 && myOccurrences[myAnchorIdxIfAll] != null ? myOccurrences[myAnchorIdxIfAll].getParent() : myAnchorElementIfAll,
|
||||
myAnchorIdx != -1 && myOccurrences[myAnchorIdx] != null ? myOccurrences[myAnchorIdx].getParent() : myAnchorElement, myEditor,
|
||||
myParentClass);
|
||||
convertToFieldRunnable.run();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user