Made changes according to requirements