Fix pep8 warning w601

.has_key() is deprecated
![screen shot 2014-10-23 at 17 05 31](https://cloud.githubusercontent.com/assets/47926/4753310/0a5622d6-5ab6-11e4-84da-e84985482ae9.png)