diff --git a/src/services/roles.js b/src/services/roles.js index d2ba71e..19a828f 100644 --- a/src/services/roles.js +++ b/src/services/roles.js @@ -2,13 +2,17 @@ * Topcoder TaaS Service for Roles */ import { axiosInstance as axios } from "./requestInterceptor"; +import _ from "lodash"; import config from "../../config"; /** * Returns a list of roles. */ export function getRoles() { - return axios.get(`${config.API.V5}/taas-roles`); + return axios.get(`${config.API.V5}/taas-roles`).then((response)=>{ + response.data = _.filter(response.data, role => _.find(role.rates, r => r.global)) + return response + }); } /**