if all children have no access then remove parent

Let me know what you think..