TheWebSolver / tws-license-manager-client

The Web Solver License Manager Client extends the functionality of License Manager for WooCommerce. This plugin/framework is to be included inside the selling plugin for license activation/deactivation.
https://github.com/TheWebSolver/tws-license-manager-client
GNU General Public License v3.0
6 stars 2 forks source link

Expired license showing as active -- License Key is now 401. #11

Open yonifre opened 2 years ago

yonifre commented 2 years ago

The license expired already but on the client site it still looks active, when I tried to manually deactivate the license on the client site, I got an error: "License Key is now 401."

Screen Shot 2022-07-13 at 11 08 19 Screen Shot 2022-07-13 at 11 10 33
hsehszroc commented 2 years ago

Have you modified lmfwc core file following this doc? This modification is required for expired license to be synced between client and server.

yonifre commented 2 years ago

Hey, I did it now, It is still not deactivated the license automatically.

When I tried to manually deactivate the license on the client site, I got an error: Your license has expired. Renew your license first.

Screen Shot 2022-08-08 at 17 21 00
hsehszroc commented 2 years ago

Since your license has expired before modifying lmfwc core file, the license status couldn't be synced. Due to this, there is no link between the license data saved on server and the license data saved on client.

For now, you can give this code a try (read below notes & guides first):

// On functions.php or any other pluggable file.
$workable_tag = 'admin_notices';
$workable_tag = 'admin_init';

add_action( $workable_tag, array( $client, 'check_license_status' ) );

Notes & guides:

There is still a chance that it might not work (let me know how it goes).

Additional notes:

yonifre commented 2 years ago

Sorry but the code give me en Php fatal error, Can you advice?