Cleaned up logging code.
Fixed bug in network code program. It now works!
Added some small logs.