tylerbutler / engineer

A static website generator written in Python.
http://engineer.readthedocs.org/
MIT License
25 stars 3 forks source link

fix slug processing to allow for numeric tags #80

Closed pridkett closed 10 years ago

pridkett commented 10 years ago

It appears that the YAML parsing is smart enough to see that something that is entirely numeric should be a number. For example:

Tags:
- 2013
- 2014

However, the slugify method assumed that the text being passed to it was actually an object with the lower method. In some cases, such as those above, it could be an int which causes engineer build to fail. By casting text to unicode we avoid this problem.