Added routing helper function and whitespace.
Made network type more strict.

Signed-off-by: Ted Steiner <tsteiner2@gmail.com>