Fixing AttachGateway