Core: fix attached composite values (#339).

Thank you dgf for reporting!

Close ticket 339.