Module:TableGenerator: Difference between revisions

Jump to navigation Jump to search
Sur (talk | contribs)
m pattern matching off
Sur (talk | contribs)
m corrected find pattern
Line 40: Line 40:
         -- If the value contains a " 0 " then it will be colored slightly darker
         -- If the value contains a " 0 " then it will be colored slightly darker
         local class = ''
         local class = ''
         if value:find("0", true) and not value:find("0.", true) then
         if value:find("0[^%.]") then
             class = ' class="darker"'
             class = ' class="darker"'
         end
         end