Fixes #3 : add gates a secodn time