mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-04-26 05:16:01 +08:00
@@ -169,7 +169,7 @@ class _FavPgcChildPageState extends State<FavPgcChildPage>
|
||||
itemBuilder: (context, index) => const FavPgcItemSkeleton(),
|
||||
itemCount: 10,
|
||||
),
|
||||
Success(:var response) =>
|
||||
Success(:final response) =>
|
||||
response != null && response.isNotEmpty
|
||||
? SliverGrid.builder(
|
||||
gridDelegate: gridDelegate,
|
||||
@@ -206,7 +206,7 @@ class _FavPgcChildPageState extends State<FavPgcChildPage>
|
||||
itemCount: response.length,
|
||||
)
|
||||
: HttpError(onReload: _favPgcController.onReload),
|
||||
Error(:var errMsg) => HttpError(
|
||||
Error(:final errMsg) => HttpError(
|
||||
errMsg: errMsg,
|
||||
onReload: _favPgcController.onReload,
|
||||
),
|
||||
|
||||
@@ -52,7 +52,7 @@ class FavPgcController
|
||||
|
||||
// 取消追番
|
||||
Future<void> pgcDel(int index, seasonId) async {
|
||||
var result = await VideoHttp.pgcDel(seasonId: seasonId);
|
||||
final result = await VideoHttp.pgcDel(seasonId: seasonId);
|
||||
if (result case Success(:final response)) {
|
||||
loadingState
|
||||
..value.data!.removeAt(index)
|
||||
@@ -97,7 +97,7 @@ class FavPgcController
|
||||
}
|
||||
|
||||
Future<void> onUpdate(int index, int followStatus, int? seasonId) async {
|
||||
var result = await VideoHttp.pgcUpdate(
|
||||
final result = await VideoHttp.pgcUpdate(
|
||||
seasonId: seasonId.toString(),
|
||||
status: followStatus,
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user