Fixed build failure by pushing CollectionResource instances directly onto the stack.