completed network class & fixed bugs