mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-25 03:26:22 +08:00
@@ -71,15 +71,16 @@ abstract class CommonSearchPageState<S extends CommonSearchPage, R, T>
|
||||
Widget _buildBody(LoadingState<List<T>?> loadingState) {
|
||||
return switch (loadingState) {
|
||||
Loading() => const HttpError(),
|
||||
Success(:var response) => response?.isNotEmpty == true
|
||||
? buildList(response!)
|
||||
: HttpError(
|
||||
onReload: controller.onReload,
|
||||
),
|
||||
Success(:var response) =>
|
||||
response?.isNotEmpty == true
|
||||
? buildList(response!)
|
||||
: HttpError(
|
||||
onReload: controller.onReload,
|
||||
),
|
||||
Error(:var errMsg) => HttpError(
|
||||
errMsg: errMsg,
|
||||
onReload: controller.onReload,
|
||||
),
|
||||
errMsg: errMsg,
|
||||
onReload: controller.onReload,
|
||||
),
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user