@Override
  protected @Nullable Presentation getPresentation(@NotNull ActionContext context, @NotNull PyIfStatement expression) {
    PyIfStatement outer = getIfStatement(expression);
    if (outer == null) return null;
    if (outer.getElsePart() != null || outer.getElifParts().length > 0) return null;
    PyStatement firstStatement = getFirstStatement(outer);
    PyStatementList outerStList = outer.getIfPart().getStatementList();
    if (outerStList.getStatements().length != 1) return null;
    if (!(firstStatement instanceof PyIfStatement inner)) return null;
    if (inner.getElsePart() != null || inner.getElifParts().length > 0) return null;
    PyStatementList stList = inner.getIfPart().getStatementList();
    if (stList.getStatements().length == 0) return null;
    return Presentation.of(PyPsiBundle.message("INTN.join.if"));
  }
@Override
  protected @Nullable Presentation getPresentation(@NotNull ActionContext context, @NotNull PyIfStatement expression)