Changeset - 182f5bd3b49d
[Not reviewed]
beta
0 1 0
Marcin Kuzminski - 14 years ago 2011-09-30 00:50:21
marcin@python-works.com
changed list comprehesion into generator
1 file changed with 3 insertions and 2 deletions:
0 comments (0 inline, 0 general)
rhodecode/controllers/summary.py
Show inline comments
 
@@ -51,6 +51,7 @@ try:
 
except ImportError:
 
    #python 2.5 compatibility
 
    import simplejson as json
 
    
 
log = logging.getLogger(__name__)
 

	
 

	
 
@@ -139,9 +140,9 @@ class SummaryController(BaseRepoControll
 
            c.commit_data = stats.commit_activity
 
            c.overview_data = stats.commit_activity_combined
 

	
 
            lang_stats = [(x, {"count": y,
 
            lang_stats = ((x, {"count": y,
 
                               "desc": LANGUAGES_EXTENSIONS_MAP.get(x)})
 
                          for x, y in lang_stats_d.items()]
 
                          for x, y in lang_stats_d.items())
 

	
 
            c.trending_languages = json.dumps(OrderedDict(
 
                                       sorted(lang_stats, reverse=True,
0 comments (0 inline, 0 general)