don't use ternary operator, not available in python 2.4
Merge pull request #7 from JensTimmerman/master

don't use ternary operator, not available in python 2.4