updated soft-delete flags

OK, maybe third time lucky :)

I've moved the check to a separate function; it's much more readable now. Fixes #92.
There should be a space before the return annotation. Also, you should use `bool` rather than `boolean`.