Better fix for issue #158

I think this is a better solution that the one I made before. Basicly it add the pk attribute to the schema. Then findOne uses that instead of finding it again.

Also had to change the test to account for the extra attribute