forward port of getAllInstances fixes, so that it never returns undef but logs warnings instead
This commit is contained in:
parent
a640222a29
commit
4de39b7fe5
2 changed files with 9 additions and 1 deletions
|
|
@ -57,6 +57,8 @@
|
|||
http://www.webgui.org/bugs/tracker/uploaded-file-sizes-wrong#8ao9yNQrxFyJNTUaU7ARPA
|
||||
- fix: Activity Sequence Numbers Incorrect when Editing Workflows (perlDreamer Consulting, LLC)
|
||||
http://www.webgui.org/bugs/tracker/activity-sequence-numbers-incorrect-when-editing-workflows#YRH7TYSWFkEUSPVDNN6zKQ
|
||||
- fix: Spectre Should Check That It Has a Valid Workflow (perlDreamer Consulting, LLC)
|
||||
http://www.webgui.org/bugs/tracker/spectre-should-check-that-it-has-a-valid-workflow#lHx4BxEUxcacX7rS5VLxeg
|
||||
|
||||
|
||||
7.3.18
|
||||
|
|
|
|||
|
|
@ -166,7 +166,13 @@ sub getAllInstances {
|
|||
my @instances = ();
|
||||
my $rs = $session->db->read("SELECT instanceId FROM WorkflowInstance");
|
||||
while (my ($instanceId) = $rs->array) {
|
||||
push(@instances, WebGUI::Workflow::Instance->new($session, $instanceId));
|
||||
my $instance = WebGUI::Workflow::Instance->new($session, $instanceId);
|
||||
if (defined $instance) {
|
||||
push(@instances, $instance);
|
||||
}
|
||||
else {
|
||||
$session->errorHandler->warn('Tried to instance instanceId '.$instanceId.' but it returned undef');
|
||||
}
|
||||
}
|
||||
return \@instances;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue