Skip to content

Refactor: Wrap http result and json serde result#50

Merged
sky130 merged 1 commit intosky130:masterfrom
AuTsing:optimize-refresh-token
Jan 27, 2026
Merged

Refactor: Wrap http result and json serde result#50
sky130 merged 1 commit intosky130:masterfrom
AuTsing:optimize-refresh-token

Conversation

@AuTsing
Copy link
Contributor

@AuTsing AuTsing commented Jan 27, 2026

Refactor: Wrap http result and json serde result to achieve a more predictable workflow

  1. 补全 MiotLoginProviderImpl 的函数签名,提升在github的阅读效率
  2. 封装 http get 的结果成 Result,方便在调用的时候抛出或者处理
  3. 封装 json 的结果成 Result,因为网络获取到的字符串没法保证反序列化时的安全性,所以感觉封装一下比较符合预期
  4. Cookie 如果是手动修改添加了两个方法,避免了歧义(我阅读到这的时候在疑惑为啥要url)

@sky130 sky130 merged commit 1332e32 into sky130:master Jan 27, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants