Made some ibg bug fixes