refactored IGV code