You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've recently updated from 1.3.1 to 1.3.4 and after a while noticed all page views have been lost in the mean time. I didn't change any settings or behaviors after the update. After a closer look on the source code, it looks like some refactor was being conducted and as far as I could understand it wasn't completed but actually released.
This commit looks like where it all changed as you can see it will call a db_prepare_insert and then db_commit_insert instead of the former db_insert.
Below you can check the actual method code with the important INSERT query commented:
// ON DUPLICATE KEY UPDATE count = count + VALUES(count)"
// );
$this->db_insert_values = '';
// return $result;
}
I'm not sure why it is commented or how did this get to a release without working and specially because it has been a long while it has happened and no one eventually noticed I am curious if there is actually a different way to do it after that release that I didn't catch.
P.S. Reverting to PVC 1.3.1 got it back working.
For the record, I am using WP 5.7 with nginx 1.18.0 and PHP 7.4.16.
Below a screenshot of relevant configuration screen:
Please let me know if I can provide any further information and be helpful on improving this great plugin!
Keep Rocking!
The text was updated successfully, but these errors were encountered:
@psielicki @bartoszarendt
I've recently updated from
1.3.1
to1.3.4
and after a while noticed all page views have been lost in the mean time. I didn't change any settings or behaviors after the update. After a closer look on the source code, it looks like some refactor was being conducted and as far as I could understand it wasn't completed but actually released.This commit looks like where it all changed as you can see it will call a
db_prepare_insert
and thendb_commit_insert
instead of the formerdb_insert
.Below you can check the actual method code with the important
INSERT
query commented:post-views-counter/includes/counter.php
Lines 671 to 686 in b205915
I'm not sure why it is commented or how did this get to a release without working and specially because it has been a long while it has happened and no one eventually noticed I am curious if there is actually a different way to do it after that release that I didn't catch.
P.S. Reverting to
PVC 1.3.1
got it back working.For the record, I am using
WP 5.7
withnginx 1.18.0
andPHP 7.4.16
.Below a screenshot of relevant configuration screen:
Please let me know if I can provide any further information and be helpful on improving this great plugin!
Keep Rocking!
The text was updated successfully, but these errors were encountered: