langcode: en
status: true
dependencies:
  module:
    - eca_base
    - eca_content
    - eca_misc
    - eca_user
    - modeler_api
third_party_settings:
  modeler_api:
    modeler_id: bpmn_io
    label: 'Unpublished 404'
id: unpublished_404
weight: 0
template: null
events:
  kernel__exception_status_code_exception:
    plugin: 'kernel:exception_status_code'
    label: 'Uncaught Exception'
    configuration: {  }
    successors:
      -
        id: eca_void_and_condition_and
        condition: eca_scalar_403
conditions:
  eca_scalar_403:
    plugin: eca_scalar
    label: '403?'
    configuration:
      negate: false
      left: '[event:code]'
      right: '403'
      operator: equal
      type: value
      case: false
  eca_entity_field_value_unpublished_1:
    plugin: eca_entity_field_value
    label: 'unpublished?'
    configuration:
      negate: true
      expected_value: '1'
      field_name: status
      operator: equal
      type: value
      case: false
      entity: node
gateways: {  }
actions:
  eca_void_and_condition_and:
    label: AND
    plugin: eca_void_and_condition
    configuration: {  }
    successors:
      -
        id: eca_switch_account_1
        condition: ''
  eca_switch_account_1:
    label: 'Switch to user 1'
    plugin: eca_switch_account
    configuration:
      user_id: '1'
    successors:
      -
        id: eca_token_load_route_param_route
        condition: ''
  eca_token_load_route_param_route:
    label: 'Load node from route'
    plugin: eca_token_load_route_param
    configuration:
      token_name: node
      request: 2
      parameter_name: node
    successors:
      -
        id: eca_throw_exception_exception
        condition: eca_entity_field_value_unpublished_1
  eca_throw_exception_exception:
    label: 'Not found exception'
    plugin: eca_throw_exception
    configuration:
      exception_type: Symfony\Component\HttpKernel\Exception\NotFoundHttpException
      response_message: ''
      log_exception: true
    successors: {  }
