Fix for JNI error when sending exceptions

Boolean object was incorrectly sent as a boolean primitive causing JNI
errors.

Fixes #8