They're trying to minimize it. They gave season ticket holders MONTHS of priority time, then had a limited sale with info sent out to people who had actually bought tickets during the season. And of course there were various anti-bot measures in place during the purchase process. There's not much more that they can do.
The Cubs were caught scalping their own tickets at one point last decade: they were selling them directly to scalpers without putting them up at the box office for face value. So it could be worse.