changing to class template