Handle exception from Nipap class

Additionally changed the order so we don't have to handle the exception
twice.

https://github.com/SpriteLink/NIPAP/issues/597