A lot of folks do not have the necessary knowledge to deeply understand the code they're writing - and I don't mean that as a diss. There's a lot of things they understand that better SWEs might not.
ChatGPT and StackOverflow both allow them to build things they otherwise couldn't, the same way e.g. cars are tools that allow people to travel faster even if they can't fix the cars or make smarter choices about where they go. At some point, that lack of knowledge will cause them harm, but that's not specific to any given tool, and the harm from ChatGPT advice isn't worse than the harm from SO advice.