Small refactoring
Renamed function path to optional