mirror of
https://github.com/JetBrains/intellij-sdk-code-samples.git
synced 2025-07-27 16:57:49 +08:00
Fix some platform API change
This commit is contained in:
parent
7b03fa6f39
commit
615676f911
@ -46,9 +46,8 @@ public class ConditionalOperatorConvertor extends PsiElementBaseIntentionAction
|
||||
return false;
|
||||
}
|
||||
|
||||
public void invoke(@NotNull Project project, Editor editor, PsiFile file) throws IncorrectOperationException {
|
||||
public void invoke(@NotNull Project project, Editor editor, PsiElement element) throws IncorrectOperationException {
|
||||
final int offset = editor.getCaretModel().getOffset();
|
||||
final PsiElement element = file.findElementAt(offset);
|
||||
PsiConditionalExpression conditionalExpression = PsiTreeUtil.getParentOfType(element,
|
||||
PsiConditionalExpression.class, false);
|
||||
if (conditionalExpression == null) return;
|
||||
|
Loading…
x
Reference in New Issue
Block a user