// ensure we update the open or close mustache for this block appropriately
if (myUpdateOpenMustache != (targetBlockMustache instanceof HbOpenBlockMustache)) {
targetBlockMustache = blockMustache.getPairedElement();
}
HbPath path = PsiTreeUtil.findChildOfType(targetBlockMustache, HbPath.class);
final Document document = PsiDocumentManager.getInstance(project).getDocument(file);
if (path != null && document != null) {
final TextRange textRange = path.getTextRange();
document.replaceString(textRange.getStartOffset(), textRange.getEndOffset(), myCorrectedName);
}
}