Patreon / patreon-php

Interact with the Patreon API via OAuth
Apache License 2.0
144 stars 40 forks source link

count(): Argument #1 ($value) must be of type Countable|array, null given #92

Open wkolcz-UMHS opened 2 years ago

wkolcz-UMHS commented 2 years ago

I am attempting to use the patreon api and I am stumbling at the first step. I stored my access token in my database and I tried to use it to access information. Using the docs, I did something simple like:

         try{
            $api_client = new API($access_token);
            $current_member = $api_client->fetch_user();
            dd($current_member);
        }catch(\Exception $e){
            dd($e->getMessage());
        }

But I am immediately hit with the error code 'count(): Argument #1 ($value) must be of type Countable|array, null given' and no other information.