create workflowList correctly.
check that workflows are not null before trying to add them