refactoring network layer
refactoring network layer