used simple function instead of bind method