Update to oauth2

LinkedIn now offers an oauth2 API endpoint.

Also did some cleanups.