Revert "making the path checking a little less restrictive, for layer support"

This reverts commit 9e8a4069d9e1f551f48391629bcdba392280a8c8.