Fixed global subs permissions logic and errors