Skip to content

Commit

Permalink
fix(main): get cookies string null
Browse files Browse the repository at this point in the history
  • Loading branch information
justorez committed Jan 10, 2024
1 parent db0f2e9 commit eac052a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

## 安装

Microsoft Edge 扩展地址:[上架审核中](#)

## 用法

Expand Down
3 changes: 2 additions & 1 deletion src/main/app.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<script setup lang="ts">
import SDK, { Comment, Reason } from './sdk'
import { getHeaderCookie } from '@/utils';
let sdk: SDK
let comments: Comment[] = [] // 当前页全部评论
Expand Down Expand Up @@ -39,7 +40,7 @@ async function init() {
myReasonId.value = ''
initBtnLoading.value = true
const cookies = (await chrome.storage.local.get('cookies')).cookies
const cookies = await getHeaderCookie()
sdk = new SDK(url.value, cookies)
const data = await sdk.init()
initBtnLoading.value = false
Expand Down

0 comments on commit eac052a

Please sign in to comment.