switched .id to .pk to catch edge cases with custom user-defined primary key fields
Merge pull request #3 from ldoubleuz/master

Use .pk instead of .id