mirror of https://gitlab.com/basile.b/dexed.git
upstream fix, result of THashMap.getData may be undefined
This commit is contained in:
parent
50615accec
commit
90dd4d79e0
|
@ -194,7 +194,9 @@ end;
|
|||
|
||||
function TLibraryItem.getModule(const value: string): TModuleInfo;
|
||||
begin
|
||||
exit(fModulesByName.GetData(value));
|
||||
result := nil;
|
||||
if fModulesByName.contains(value) then
|
||||
exit(fModulesByName.GetData(value));
|
||||
end;
|
||||
|
||||
function TLibraryItem.addModuleInfo: TModuleInfo;
|
||||
|
@ -427,7 +429,9 @@ end;
|
|||
|
||||
function TLibraryManager.getLibraryByAlias(const value: string): TLibraryItem;
|
||||
begin
|
||||
exit(fItemsByAlias.GetData(value));
|
||||
result := nil;
|
||||
if fItemsByAlias.contains(value) then
|
||||
exit(fItemsByAlias.GetData(value));
|
||||
end;
|
||||
|
||||
function TLibraryManager.getLibraryByImport(const value: string): TLibraryItem;
|
||||
|
|
Loading…
Reference in New Issue