Added checking for optional service plan fields before unboxing.

Fixes #153.