Allow falsy ID for plans

I encountered this issue, and saw that this was already reported in #55.
The fix I've included will solve the issue, but might impact other things, so this should be tested carefully.