1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-08-06 22:30:57 +00:00
* Fixed: Emotes not appearing in Chat on Videos.
* Fixed: Extra, unnecessary `Pause Chat` section appearing in the Twitch chat settings menu.
* Fixed: Hide the number of unread whispers when hiding the whispers button.
* Fixed: The alternative live viewer display sometimes incorrectly displaying zero when loading the page.
* Fixed: Precision issue when displaying localized numbers in some cases.
This commit is contained in:
SirStendec 2020-09-15 19:17:29 -04:00
parent 943e0fdc18
commit 472f9472ee
8 changed files with 93 additions and 14 deletions

View file

@ -265,6 +265,29 @@ export default class TwitchData extends Module {
return get('data.user', data);
}
/**
* Queries Apollo for the user's current game, details given the user id or name. One of (id, login) MUST be specified
* @function getUserGame
* @memberof TwitchData
* @async
*
* @param {int|string|null|undefined} id - the user id number (can be an integer string)
* @param {string|null|undefined} login - the username
* @returns {Object} information about the requested user
*
* @example
*
* console.log(this.twitch_data.getUserGame(19571641, null));
*/
async getUserGame(id, login) {
const data = await this.queryApollo(
await import(/* webpackChunkName: 'queries' */ './data/user-game.gql'),
{ id, login }
);
return get('data.user.broadcastSettings.game', data);
}
/**
* Queries Apollo for the logged in user's relationship to the channel with given the id or name. One of (id, login) MUST be specified
* @function getUserSelf