mirror of
https://github.com/lifegpc/eh_downloader_flutter.git
synced 2026-07-08 01:30:28 +08:00
feat: 添加画廊列表显示模式和合并功能,优化画廊列表卡片组件
This commit is contained in:
@@ -27,6 +27,14 @@ class ApiResult<T> {
|
||||
}
|
||||
}
|
||||
|
||||
T? unwrapOrNull() {
|
||||
if (ok) {
|
||||
return data;
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
(int, String) unwrapErr() {
|
||||
if (ok) {
|
||||
return throw 'unwrap_err called on ok ApiResult';
|
||||
|
||||
Reference in New Issue
Block a user