cleaned up code format