Added more hoisting code