Fixed stitch limit bug

pull/3/head
Brenda 2017-01-10 20:31:42 -05:00 zatwierdzone przez GitHub
rodzic a2d790b7f7
commit bfd29a105d
1 zmienionych plików z 3 dodań i 3 usunięć

Wyświetl plik

@ -115,10 +115,10 @@ class Layout:
self.card_stitches = stitches
self.card_rows = rows
if self.card_rows > 200 or self.card_stitches > 30:
if self.card_rows > 200 or self.card_stitches > specs[machine_id]['stitches']:
raise ValueError(
"Your pattern seems to exceed 200 rows and/or 30 stitches. "
"Are you sure you uploaded the right text file?")
"Your pattern seems to exceed 200 rows and/or {} stitches. "
"Are you sure you uploaded the right text file?".format(specs[machine_id]['stitches']))
self.horz_repeat = horz_repeat
self.vert_repeat = vert_repeat