started adding function