Fix referencing attributes from outputs within resources.