Create function to check if access token is present

I've been using this function to check whether the access_token is set, since the `$access_token` variable is protected I can't directly access it to check its value.

Just a convenience function, would like to know what you think.