Updated wrapper for handling exceptions applied