Added authorization check