diff --git a/polymod/fs/BaseFileSystem.hx b/polymod/fs/BaseFileSystem.hx index 08a5dd85..d14fdb56 100644 --- a/polymod/fs/BaseFileSystem.hx +++ b/polymod/fs/BaseFileSystem.hx @@ -274,7 +274,7 @@ abstract class BaseFileSystem implements IFileSystem var iconFile = getModIconPath(modPath, origin); - if (exists(iconFile)) + if (iconFile != null && exists(iconFile)) { var iconBytes:Null = getFileBytes(iconFile); @@ -370,7 +370,7 @@ abstract class BaseFileSystem implements IFileSystem var iconFile = getModIconPath(modPath, origin); - if (exists(iconFile)) + if (iconFile != null && exists(iconFile)) { var iconBytes:Null = getFileBytes(iconFile); diff --git a/polymod/fs/SysZipFileSystem.hx b/polymod/fs/SysZipFileSystem.hx index d52a3cef..7b364650 100644 --- a/polymod/fs/SysZipFileSystem.hx +++ b/polymod/fs/SysZipFileSystem.hx @@ -306,7 +306,7 @@ class SysZipFileSystem extends SysFileSystem var iconFile = getModIconPath(modId, origin); - if (exists(iconFile)) + if (iconFile != null && exists(iconFile)) { var iconBytes:Null = getFileBytes(iconFile);