added add gate to module