 
         # Add all the measure tds to row i for count n, record r
         generateRecord = (info) ->
-          ms = info.cols.metrics
-          return unless l = ms.length
-          t = info.count
+          return unless l = info.cols.metrics.length # impossible?
           if td = generateMultiple(info)
             unless info.hasOwnProperty('n')
               cls = info.p
-              for n in [0..t-1] by 1
+              for n in [0..info.count-1] by 1
                 td.classList.add(cls + info.row.get(info.c, n).id)
             return
           pre = ID + '-' + info.i + '_'

              cn = constants.release[v]
              cell.className = cn + ' release icon hint-release-' + cn
              v = ''
            when 'id'
              if v?
                cell.className = 'icon ' + if Editing && Key.id != info.c then 'trash' else 'bullet'
                v = ''
            when 'age'

        generateAdd = (info, td) ->
          width = info.cols.metrics.length
          info.m = info.cols.start
          if typeof info.metric.id == 'number' && info.metric.name != 'indicator'
            info.id = ID+'-'+info.i+'_'+info.cols.start+(if info.hasOwnProperty('n') then '_'+info.n else '')
            generateCell(info)
            info.tr.insertBefore(info.cell, td)
