Minor fix for backward compatibility

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/data-publishing/document-store-lib@124625 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Luca Frosini 2016-02-26 11:11:15 +00:00
parent afa0e6719a
commit d627816f70
1 changed files with 2 additions and 0 deletions

View File

@ -177,6 +177,7 @@ public class RecordUtility {
* @return the Record
* @throws Exception if deserialization fails
*/
@SuppressWarnings("unchecked")
public static Record getRecord(Map<String, ? extends Serializable> recordMap) throws Exception {
String className = (String) recordMap.get(Record.RECORD_TYPE);
@ -189,6 +190,7 @@ public class RecordUtility {
*/
if(className == null){
className = (String) recordMap.get("usageRecordType");
((Map<String, Serializable>) recordMap).put(Record.RECORD_TYPE, className);
}
/* END of Patch */