onClose and redirectOnClose are mutually exclusive

Fix an error in #2462