Skip to content

Commit

Permalink
Merge pull request #10 from akx/token-fix
Browse files Browse the repository at this point in the history
Support new boot_data format
  • Loading branch information
Fauntleroy authored Mar 12, 2019
2 parents a117643 + 6861131 commit f1c906a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/get-slack-api-data.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ export default function getSlackApiData () {
return;
}

const apiTokenResult = /api_token\:\s\"(.*)\"/g.exec(script.innerText);
const versionUidResult = /version_uid\:\s\"(.*)\"/g.exec(script.innerText);
const apiTokenResult = /["]?api_token["]?\:\s*\"(.+?)\"/g.exec(script.innerText);
const versionUidResult = /["]?version_uid["]?\:\s*\"(.+?)\"/g.exec(script.innerText);

if (apiTokenResult) {
apiToken = apiTokenResult[1];
Expand Down

0 comments on commit f1c906a

Please sign in to comment.