willpublicmedia / npr-api-expressionengine

Access the NPR API from within ExpressionEngine.
1 stars 1 forks source link

Wrong argument type in npr_api_expressionengine->query_by_url() #45

Open areynold opened 1 year ago

areynold commented 1 year ago

When pulling a story, npr_api_expressionengine->query_by_url() passes the wrong argument type to array_key_exists, resulting in the following fatal error:

TypeError Caught
array_key_exists(): Argument #2 ($array) must be of type array, IllinoisPublicMedia\NprStoryApi\Libraries\Dto\Http\Api_response given

user/addons/npr_story_api/libraries/publishing/npr_api_expressionengine.php:39
areynold commented 1 year ago

affects php 8+

areynold commented 1 year ago

same error exists on user/addons/npr_story_api/ext.npr_story_api.php:555