Commit 78f1796374558c6b4782b9330c940dd053310ce4
Exists in
master
and in
4 other branches
Merge branch 'fix-issue-28'
Showing
1 changed file
with
0 additions
and
11 deletions
Show diff stats
src/app/components/article-service/article.service.js
@@ -118,7 +118,6 @@ | @@ -118,7 +118,6 @@ | ||
118 | 118 | ||
119 | UtilService.get(url, {params: paramsExtended}).then(function(data){ | 119 | UtilService.get(url, {params: paramsExtended}).then(function(data){ |
120 | _pipeInjectSlugIntoParentProgram(data); | 120 | _pipeInjectSlugIntoParentProgram(data); |
121 | - _pipeSortByRankinPosition(data); | ||
122 | cbSuccess(data); | 121 | cbSuccess(data); |
123 | }).catch(function(error){ | 122 | }).catch(function(error){ |
124 | cbError(error); | 123 | cbError(error); |
@@ -283,7 +282,6 @@ | @@ -283,7 +282,6 @@ | ||
283 | 282 | ||
284 | UtilService.get(url, {params: paramsExtended}).then(function(data){ | 283 | UtilService.get(url, {params: paramsExtended}).then(function(data){ |
285 | _pipeInjectSlugIntoParentProgram(data); | 284 | _pipeInjectSlugIntoParentProgram(data); |
286 | - _pipeSortByRankinPosition(data); | ||
287 | cbSuccess(data); | 285 | cbSuccess(data); |
288 | }).catch(function(error){ | 286 | }).catch(function(error){ |
289 | cbError(error); | 287 | cbError(error); |
@@ -303,15 +301,6 @@ | @@ -303,15 +301,6 @@ | ||
303 | } | 301 | } |
304 | } | 302 | } |
305 | 303 | ||
306 | - function _pipeSortByRankinPosition(data){ | ||
307 | - if(!data.articles && data.article){ | ||
308 | - data.articles = [data.article]; | ||
309 | - } | ||
310 | - data.articles = data.articles.sort(function(pA, pB){ | ||
311 | - return pA.ranking_position - pB.ranking_position; | ||
312 | - }); | ||
313 | - } | ||
314 | - | ||
315 | function _pipeRemoveOldEvents(data){ | 304 | function _pipeRemoveOldEvents(data){ |
316 | if(!data.articles && data.article){ | 305 | if(!data.articles && data.article){ |
317 | data.articles = [data.article]; | 306 | data.articles = [data.article]; |