work with new oauth system (popup / redirect)