We generally avoid temporary variables for various reasons (see coding standards document). Please use:

```foreach ( $this->attribute( 'assigned_nodes' ) as $assignedNode )```