Fix bug in generator code where a connection is not properly propagated.