public function StateFlow::load in State Machine 7
Same name and namespace in other branches
- 6 modules/state_flow/plugins/state_flow.inc \StateFlow::load()
- 7.2 modules/state_flow/plugins/state_flow.inc \StateFlow::load()
Load the current state from the given state storage
Overrides StateMachine::load
File
- modules/
state_flow/ plugins/ state_flow.inc, line 146
Class
Code
public function load() {
$state = FALSE;
if (!empty($this->object->vid)) {
$state = $this
->revision_state($this->object->vid);
}
elseif (!empty($this->object->nid)) {
$state = $this
->latest_state($this->object->nid);
}
return $state;
}