Finished Adoption code