Merge pull request #27 from wimvelzeboer/RecordType-patch

Fix issue with fflib_RecordType when cache is null
This commit is contained in:
William Velzeboer
2022-01-29 21:09:49 +00:00
committed by GitHub
@@ -63,6 +63,7 @@ public class fflib_RecordTypeId
String sObjectName,
String recordTypeName)
{
if (cache == null) cache = new Map<String, Map<String, RecordTypeInfo>>();
if (cache.containsKey(sObjectName)) return getRecordTypeIdFromCache(cache, sObjectName, recordTypeName);
Map<String, RecordTypeInfo> recordTypeInfosByName = fflib_SObjectDescribe.getDescribe(sObjectName)