NXP-15363: fix NPE when testing permission on parent document