inkle/ink

Don't throw exception from ContentAtPath

Offen

#211 geöffnet am 16.10.2016

 (0 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)C# (466 Forks)batch import
enhancementhelp wanted

Repository-Metriken

Stars
 (3.743 Sterne)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

Container's ContentAtPath currently throws an exception if it fails, which creates some rather ugly try/catch code in a number of places where we want to be able to fail gracefully if the content can't be found.

Convert ContentAtPath to return null if it doesn't find the content, and throw exceptions at the call site where it's still intended. (Such as in the main Step() function).

Note that this should be relatively straightforward if anyone wants to give it a try! (Though not before #210 is fixed so you can verify your code!)

Contributor Guide