diff --git a/SeedDMS_Core/Core/inc.ClassWorkflow.php b/SeedDMS_Core/Core/inc.ClassWorkflow.php index 329b79cc9..ea104dee0 100644 --- a/SeedDMS_Core/Core/inc.ClassWorkflow.php +++ b/SeedDMS_Core/Core/inc.ClassWorkflow.php @@ -150,8 +150,13 @@ class SeedDMS_Core_Workflow { /* {{{ */ return $this->_transitions; } /* }}} */ - /** - * @return array + /** + * Get all states this workflow at some point may reach + * + * It basically iterates through all transistions and makes a unique + * list of the start and end state. + * + * @return array list of states */ function getStates() { /* {{{ */ /** @noinspection PhpUnusedLocalVariableInspection */ @@ -161,7 +166,7 @@ class SeedDMS_Core_Workflow { /* {{{ */ $this->getTransitions(); $states = array(); - foreach($this->_transitions as $transition) { + foreach($this->_transitions as $transition) { if(!isset($states[$transition->getState()->getID()])) $states[$transition->getState()->getID()] = $transition->getState(); if(!isset($states[$transition->getNextState()->getID()]))