refs and minor changes