- adding an internal exception handler to catch InvalidOperationException and throw a new explicit one