Add type checking to return value
Add type checking to return value

When this fails with false it throws an exception before that boolean is
an invalid return type. Convert it to an exception instead.

dartajax/ilios,stopfstedt/ilios,stopfstedt/ilios,ilios/ilios,dartajax/ilios,thecoolestguy/ilios,Trott/ilios,ilios/ilios,thecoolestguy/ilios,Trott/ilios