updated populate method
refactor status code and finished CRUD tests