improve readme, fix finding correct parent
refactor

implemented some changes suggested by [hpop](https://github.com/hpop).
thx!