added parameter validation for __contains__ run on empty dictionary
simplified contains - removed premature optimization
Merge pull request #221 from paweljasinski/cp35348

fixed cp35348