Don't crash when user can't edit tree

fixes #110 on github