Skip to content

Commit

Permalink
fix: no warnings for missing AddressableImportSettings #15
Browse files Browse the repository at this point in the history
  • Loading branch information
favoyang committed Feb 2, 2020
1 parent 15f556f commit 30dd56a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Editor/AddressableImporter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,11 @@ static void OnPostprocessAllAssets(string[] importedAssets, string[] deletedAsse
{
var settings = AddressableAssetSettingsDefaultObject.Settings;
var importSettings = AddressableImportSettings.Instance;
if (importSettings == null || importSettings.rules == null || importSettings.rules.Count == 0)
if (importSettings == null) {
Debug.LogFormat("[AddressableImporter] import settings file not found\nPlease go to Assets/AddressableAssetsData folder, right click in the project window and choose 'Create > Addressable Assets > Import Settings'.");
return;
}
else if (importSettings.rules == null || importSettings.rules.Count == 0)
return;
var entriesAdded = new List<AddressableAssetEntry>();
foreach (string assetPath in importedAssets)
Expand Down

0 comments on commit 30dd56a

Please sign in to comment.