Rework exception handling