hopfully it's now more pythonic :D