inTransaction() nowadays casts the in_transaction result to boolean. I'm not sure whether the INERROR state should result in true or false. For now I went with the result that we actually get.