Utility functions for copying properties from one JavaScript object to another