Suspicious instanceOf test

Description

In executeParse() of org.activiti.engine.impl.bpmn.parser.handler.SubProcessParseHandler a parameter to the method is a SubProcess object called subProcess.

At line 43 there is a test for a subclass of Subprocess:
if (subProcess instanceof EventSubProcess)

At line 58 there is a comment about the subclass (event subprocesses):
// no data objects for event subprocesses

But the following line tests for the super class (SubProcess):
if (subProcess instanceof SubProcess)

This test is correct then it is redundant as subProcess is defined as a SubProcess object.

I suspect that test should be for the subclass to match the comment:
if (subProcess instanceof EventSubProcess)

Environment

None

Assignee

Joram Barrez

Reporter

David Malkovsky

Labels

None

Components

Fix versions

Affects versions

Priority

Major
Configure