Fixed PropertyBag:copy() to correctly copy foreign properties