Fix renaming of citation refs after changing bibitem key

Fixes: #6494
This commit is contained in:
Juergen Spitzmueller 2019-04-21 09:55:17 +02:00
parent 5c0ea92f80
commit faefee3dc6

View File

@ -155,8 +155,9 @@ void InsetBibitem::doDispatch(Cursor & cur, FuncRequest & cmd)
setParam("literal", p["literal"]);
if (p["key"] != old_key) {
cur.recordUndoFullBuffer();
cur.bv().buffer().changeRefsIfUnique(old_key, p["key"]);
updateCommand(p["key"]);
cur.bv().buffer().changeRefsIfUnique(old_key, params()["key"]);
cur.forceBufferUpdate();
buffer().invalidateBibinfoCache();
}