Skip to content

Commit

Permalink
League of graphs: removed roles slicing
Browse files Browse the repository at this point in the history
  • Loading branch information
Ryzzzen committed Feb 17, 2019
1 parent fd5fe22 commit eab3d09
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions objects/providers/LeagueofGraphs.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,8 @@ class LeagueofGraphsProvider extends Provider {
let data = { roles: {} };
let roles = gameMode === 'ARAM' ? ['ARAM'] : ['JUNGLE', 'MIDDLE', 'TOP', 'ADC', 'SUPPORT'];

if (gameMode !== 'ARAM') {
if (preferredPosition)
roles = roles.sort((a, b) => b === preferredPosition)

roles = roles.slice(0, parseInt(Mana.getStore().get('champion-select-min-roles', 5)));
}
if (gameMode !== 'ARAM' && preferredPosition)
roles = roles.sort((a, b) => b === preferredPosition)

for (let x of roles) {
console.log(2, `[ProviderHandler] [League of Graphs] Gathering data (${x})`);
Expand Down

0 comments on commit eab3d09

Please sign in to comment.