Additional logic to set properties correctly.