using closures directly to get the pathes rather than singletons and objects