Check permissions when adding a treenode