v1.7

Cleanup code