Wdym? Type2 means you aare resistant to insuline (hormone to downregulate blood sugar), so you have to avoid sugar.
Type1 means you don't produce insuline (you can still use artificial one though via injection). Even for those it's better, cuz you don't have to inject anything and it avoids the nerve damaging sugar spikes (some people have permenently attached insuline pumps on their arm though these day).
You only need sugar, when you injected to much insuline or moved to much for the amount you injected. (You have to substract physical activity burning sugar from your injection dosis beforehand; it's sometimes hard to calculate/ to know beforehand).
BTW erythritol is bet cuz it tastes like sugar.