Skip to content

Commit

Permalink
fix: mixin
Browse files Browse the repository at this point in the history
  • Loading branch information
whes1015 committed Nov 29, 2024
1 parent d59cfea commit 900f60a
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions docs/trem/plugin_dev/mixin.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,10 @@ TREM.class.ReportManager 的原生 refresh 方法。

```js
async refresh() {
console.log(user);
const url =
TREM.constant.URL.API[
Math.floor(Math.random() * TREM.constant.URL.API.length)
];
console.log(user); // 在不注入的清況下會報錯(搭配下方基本注入)
const url = TREM.constant.URL.API[Math.floor(Math.random() * TREM.constant.URL.API.length)];
const reportList = await this.getReport(url);
if (!reportList) {
return;
}
if (!reportList) return;
}
```

Expand Down

0 comments on commit 900f60a

Please sign in to comment.