Changeset 79


Ignore:
Timestamp:
12/27/10 17:08:05 (14 years ago)
Author:
atzm
Message:

fixed a bug, minus value

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pycodebattler/trunk/pycodebattler/score.py

    r71 r79  
    135135                                       token.NAME, token.COLON]) 
    136136        score = self.uncommented_bytes() - data_bytes 
     137        if score < 1: 
     138            score = 1 
    137139        score /= (self.uncommented_rows() / coefficient) or 1 
    138140        score /= self._estyle 
     
    146148                                       token.NAME, token.COLON]) 
    147149        score = self.uncommented_bytes() - data_bytes 
     150        if score < 1: 
     151            score = 1 
    148152        score /= (maxlen / self.uncommented_rows()) or 1 
    149153        score /= self.uncommented_rows() 
Note: See TracChangeset for help on using the changeset viewer.