Commits

Ben Hodgson  committed 58a3762

Fixing a bug in Code 39 barcodes in which the middle code was not included between the first edge character and the first code character

  • Participants
  • Parent commits 125011c

Comments (0)

Files changed (1)

File barcode/codex.py

                 return k
 
     def build(self):
-        c = EDGE
+        chars = [EDGE]
         for char in self.code:
-            c += MAP[char][1]
-            c += MIDDLE
-        c += EDGE
-        return [c]
+            chars.append(MAP[char][1])
+        chars.append(EDGE)
+        return [MIDDLE.join(chars)]
 
     def render(self, write_text=True, **writer_options):
         options = dict(module_width=MIN_SIZE, quiet_zone=MIN_QUIET_ZONE)