1
0
mirror of https://git.tt-rss.org/git/tt-rss.git synced 2025-12-13 04:05:55 +00:00

score: get correct classes for rows/score icons on the client

This commit is contained in:
Andrew Dolgov
2018-12-11 10:00:54 +03:00
parent fd6f3e7f07
commit 25ca144bb7
5 changed files with 49 additions and 67 deletions

View File

@@ -254,10 +254,7 @@ class Article extends Handler_Protected {
$sth->execute(array_merge([$score], $ids, [$_SESSION['uid']]));
print json_encode(array("id" => $ids,
"score" => (int)$score,
"score_class" => get_score_class($score),
"score_pic" => get_score_pic($score)));
print json_encode(["id" => $ids, "score" => (int)$score]);
}
function getScore() {
@@ -269,9 +266,7 @@ class Article extends Handler_Protected {
$score = $row['score'];
print json_encode(array("id" => $id,
"score" => (int)$score,
"score_pic" => get_score_pic($score)));
print json_encode(["id" => $id, "score" => (int)$score]);
}