owa-php-sdk icon indicating copy to clipboard operation
owa-php-sdk copied to clipboard

Deprecated code warnings

Open wernight opened this issue 4 months ago • 0 comments

Affected Version(s): 1.0.8

PHP Version: 8.2 FPM

Webserver: Nginx

Browser: N/A

Description

Creation of dynamic property OwaSdk\Tracker\TrackerClient::$site_id is deprecated

Triggered from https://github.com/Open-Web-Analytics/owa-php-sdk/blob/master/src/Tracker/TrackerClient.php#L1236

How to reproduce

Just run the getting started sample code.

Possible Solution

Just declare $site_id member field (like the others) before assigning it.

Hotfix:

sed -i '/var $config;/a    var $site_id;' vendor/open-web-analytics/owa-php-sdk/src/Tracker/TrackerClient.php

Additional context

I see no recent update on this project for a few years, which I can understand, but wondering if you're still handling PR requests as I see some pending. Most of the fixes should be fairly trivial.

wernight avatar Feb 08 '24 09:02 wernight