mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
feat: rcmd(app)/hot: filter zone
Closes #119 Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -144,6 +144,12 @@ class VideoHttp {
|
||||
(!enableRcmdDynamic ? i['card_goto'] != 'picture' : true) &&
|
||||
(i['args'] != null &&
|
||||
!blackMidsList.contains(i['args']['up_id']))) {
|
||||
String banWordForZone = GStorage.banWordForZone;
|
||||
if (banWordForZone.isNotEmpty &&
|
||||
RegExp(banWordForZone, caseSensitive: false)
|
||||
.hasMatch(i['args']['rname'])) {
|
||||
continue;
|
||||
}
|
||||
RecVideoItemAppModel videoItem = RecVideoItemAppModel.fromJson(i);
|
||||
if (!RecommendFilter.filter(videoItem)) {
|
||||
list.add(videoItem);
|
||||
@@ -171,6 +177,12 @@ class VideoHttp {
|
||||
!RecommendFilter.filterTitle(i['title']) &&
|
||||
!RecommendFilter.filterLikeRatio(
|
||||
i['stat']['like'], i['stat']['view'])) {
|
||||
String banWordForZone = GStorage.banWordForZone;
|
||||
if (banWordForZone.isNotEmpty &&
|
||||
RegExp(banWordForZone, caseSensitive: false)
|
||||
.hasMatch(i['tname'])) {
|
||||
continue;
|
||||
}
|
||||
list.add(HotVideoItemModel.fromJson(i));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user