rebuild

save function added