//--- get metadata from session
Element md = getMetadataFromSession(session, id);
//--- get element to remove
EditLib editLib = dataManager.getEditLib();
Element el = editLib.findElement(md, elementId);
if (el != null) {
Pair<Namespace, String> attInfo = parseAttributeName(attributeName, ":", id, md, editLib);
el.removeAttribute(attInfo.two(), attInfo.one());
}