#3 Adding initial error messages for authorize
#2 executing the logic in parts with the assistance of next() and done() methods