Moved older style when_failed to when with return code since it wasn't working with ansible master branch, but tested to still work with ansible 1.2