We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 795c87e commit b432dcdCopy full SHA for b432dcd
Assets/Editor Toolbox/Editor/Management/ToolboxManager.cs
@@ -213,7 +213,12 @@ void ReintializeProvider()
213
214
if (GUILayout.Button("Create a new settings file"))
215
{
216
- var settingsInstance = ScriptableObject.CreateInstance(settingsType);
+ var settingsInstance = ScriptableObject.CreateInstance<ToolboxEditorSettings>();
217
+ if (settingsInstance == null)
218
+ {
219
+ ToolboxEditorLog.LogError($"Something went wrong. Cannot create a new Settings file.");
220
+ return;
221
+ }
222
223
var locationPath = EditorUtility.OpenFolderPanel("New Settings file location", "Assets", "");
224
//validate returned path and create relative one if possible
0 commit comments