Created pid instance variable so value can be retained after destroy

Fixes #422
But then, it would still check the inner object next time pid was called. So it's probably okay.