fix constructor && get head to work