Merge pull request #594 from MDMCK10/dev

Fix Poe issues
This commit is contained in:
Cohee
2023-06-29 01:10:13 +03:00
committed by GitHub

View File

@@ -369,13 +369,13 @@ class Client {
const nextData = JSON.parse(jsonText);
this.formkey = extractFormKey(r.data);
this.viewer = nextData.props.pageProps.payload.viewer;
this.viewer = nextData.props.pageProps.data.viewer;
return nextData;
}
async get_bots() {
const viewer = this.next_data.props.pageProps.payload.viewer;
const viewer = this.next_data.props.pageProps.data.viewer;
if (!viewer.availableBotsConnection) {
throw new Error('Invalid token.');
}
@@ -398,7 +398,7 @@ class Client {
cached_bots[url] = r;
}
const chatData = r.data.pageProps.payload.chatOfBotDisplayName;
const chatData = r.data.pageProps.data.chatOfBotDisplayName;
bots[chatData.defaultBotObject.nickname] = chatData;
resolve();