void (final ImportCandidateHolder item) { PsiElement src = item.getImportable(); if (src == null) { return; } WriteCommandAction.writeCommandAction(src.getProject(), myTarget.getContainingFile()) .withName(PyPsiBundle.message("ACT.CMD.use.import")) .run(() -> doIt(item)); if (myOnDoneCallback != null) { myOnDoneCallback.run(); } }