Fixed getnodes()

Function was broken on some weird http check.
Also added to get first layer of properties as depth can be specified.
Should be extended to generic mechanism to match depth fully.