Make sure that rangy is initialized only once and that it is initialized before it is used.

Change-Id: Ia318908d34e82ae97ae1bf662ad9fc5dc28bf6ba