OK, I see.
It's many years since I worked with SRM. One thing that I remember was that it seemed that lots of things related to workflows was supposed to be done with the BAdIs. (If I tried to do certain changes to the workflow, I ran into some strange errors that I was not expecting.) Perhaps this is one of those things. Perhaps the code inside the check function should be in one of the methods of certain BAdI. This is just speculation from my part, and probably you are already fully aware of this possibility and know there isn't such a BAdI...
Kind regards,
Karri