Change authorization method to use class attributes