public void update(long storeId, Map<String, String> details) {
TransactionLegacy txn = TransactionLegacy.currentTxn();
SearchCriteria<ImageStoreDetailVO> sc = storeSearch.create();
sc.setParameters("store", storeId);
txn.start();
expunge(sc);
for (Map.Entry<String, String> entry : details.entrySet()) {
ImageStoreDetailVO detail = new ImageStoreDetailVO(storeId, entry.getKey(), entry.getValue());
persist(detail);
}