Reformatted ns declarations to be slightly more aesthetically pleasing.
Cleanup on nodes / edges query code.