Skip to content

Commit 1d56d31

Browse files
committed
selectedTypes small bug fix
1 parent 84e85c0 commit 1d56d31

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Assets/Editor/Editor Windows/ScriptableObjectEditorWindow.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,7 @@ void AddNewSO(Type type)
138138

139139
private void LoadAvailableTypes()
140140
{
141+
selectedTypes.Clear();
141142
// Scan the "ScriptableObjects" folder to find all unique ScriptableObject types
142143
availableTypes = Resources.LoadAll<ScriptableObject>("ScriptableObjects").Select(t => t.GetType()).Distinct().ToList();
143144
foreach (var filter in BasicFilters)
@@ -154,7 +155,7 @@ private void LoadAvailableTypes()
154155

155156
if (selectedTypes.Count == 0)
156157
{
157-
Debug.LogWarning("no saved filter found for ScriptableObject Editor Window");
158+
Debug.LogWarning("no saved filter found for ScriptableObject Editor Window.");
158159
selectedTypes.AddRange(availableTypes);
159160
}
160161
}

0 commit comments

Comments
 (0)