Molecular lock regulates binding of glycine to a primitive NMDA receptor