Skip to content
This repository was archived by the owner on Nov 14, 2024. It is now read-only.

Commit 47000c5

Browse files
committed
actual file
1 parent 6fe761a commit 47000c5

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

app/train.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,9 @@ def generate_fixtures(categories):
6565

6666
# validate slug length
6767
for cat in cats:
68-
if len(cat) >= 50:
69-
print("Warning invalid slug {}".format(cat))
68+
slug = cats[cat]['fields']['slug']
69+
if len(slug) > 50:
70+
print("Warning invalid slug: {slug}, length: {length}".format(slug=slug, length=len(slug)))
7071

7172
return cats.values()
7273

0 commit comments

Comments
 (0)