Skip to content

Commit

Permalink
4.4.66
Browse files Browse the repository at this point in the history
  • Loading branch information
pixelbart committed Dec 6, 2021
1 parent ae3d848 commit 60639d6
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
8 changes: 3 additions & 5 deletions core/helpers/class-stats.php
Original file line number Diff line number Diff line change
Expand Up @@ -1070,6 +1070,7 @@ public static function get_most_helpful($limit = null, $post_type = null)

$query = maybe_unserialize($query);
$posts = [];
$results = [];

if ($query->found_posts) {
foreach ($query->posts as $post_id):
Expand All @@ -1079,10 +1080,8 @@ public static function get_most_helpful($limit = null, $post_type = null)
endforeach;

if (1 < count($posts)) {

arsort($posts);

$results = [];
$posts = array_slice($posts, 0, $limit, true);

foreach ($posts as $post_id => $value):
Expand Down Expand Up @@ -1164,6 +1163,7 @@ public static function get_least_helpful($limit = null, $post_type = null)

$query = maybe_unserialize($query);
$posts = [];
$results = [];

if ($query->found_posts) {
foreach ($query->posts as $post_id):
Expand All @@ -1173,10 +1173,8 @@ public static function get_least_helpful($limit = null, $post_type = null)
endforeach;

if (1 < count($posts)) {

arsort($posts);

$results = [];

$posts = array_slice($posts, 0, $limit, true);

foreach ($posts as $post_id => $value):
Expand Down
2 changes: 1 addition & 1 deletion helpful.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/**
* Plugin Name: Helpful
* Description: Add a fancy feedback form under your posts or post-types and ask your visitors a question. Give them the abbility to vote with yes or no.
* Version: 4.4.65
* Version: 4.4.66
* Author: Pixelbart
* Author URI: https://pixelbart.de
* Text Domain: helpful
Expand Down
2 changes: 1 addition & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Tags: helpful, poll, feedback, reviews, vote, review, voting
Requires at least: 4.6
Tested up to: 5.8
Requires PHP: 5.6.20
Stable tag: 4.4.65
Stable tag: 4.4.66
License: MIT License
License URI: https://opensource.org/licenses/MIT

Expand Down

0 comments on commit 60639d6

Please sign in to comment.