Only set default_action if it's defined.