Add more descriptive exception (#7591)
* Add more descriptive exepection * Finish with . * Update src/Umbraco.Core/Collections/TopoGraph.cs Co-Authored-By: Sebastiaan Janssen <sebastiaan@umbraco.com> * Update src/Umbraco.Core/Collections/TopoGraph.cs Co-Authored-By: Sebastiaan Janssen <sebastiaan@umbraco.com> Co-authored-by: Sebastiaan Janssen <sebastiaan@umbraco.com>
This commit is contained in:
@@ -126,7 +126,7 @@ namespace Umbraco.Core.Collections
|
||||
if (_items.TryGetValue(key, out value))
|
||||
yield return value;
|
||||
else if (throwOnMissing)
|
||||
throw new Exception(MissingDependencyError);
|
||||
throw new Exception($"{MissingDependencyError} Error in type {typeof(TItem).Name}, with key {key}");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user