cleaned up file and made types consistent