The thing is, this news story may not be complete tosh.
There are definite links between low magnesium and irregular heart beats. In fact irregular heart beats are listed as a symptom of low Mag on every site I have checked. Here is are some examples.
https://ketodietapp.com/Blog/lchf/the-importance-of-magnesium-in-low-carb-diets
https://drbubbs.com/blog/2017/1/top-3-mineral-deficiencies-on-a-ketogenic-diet-and-how-to-fix-it
https://www.healthline.com/nutrition/magnesium-deficiency-symptoms#section7
Then there are links between low carb eating, and lower intake of certain nutrients - including magnesium and postassium, both of which contribute to keto flu and muscle function - and irregular heart beats, when levels get low enough.
https://www.dietdoctor.com/low-carb/keto/supplements
https://perfectketo.com/keto-micronutrients/
Of course, the study quoted in the news article is not talking about keto, or even about low carbing (in the sense it is used on this forum, which is usually under 130g carbs a day).
And it is perfectly possible to get all necessary nutrients when people follow a
well formulated keto or low carb diet, with a range of foods in the needed in appropriate portion sizes. There are many, many magnesium and potassium rich foods available to low carb/ketoers, if they choose to eat them.
If anyone wants to check whether they are hitting the recommended daily amounts of vitamins, minerals, protein and omegas, then there are some excellent Apps out there which will track things for you. I use the free version of Cronometer. It was quite an eye opener for me, and my diet is now
more well formulated than it was!
As with most things, the longer we keep doing something, the more 'normal' it feels, and the more likely we are to rack up long term consequences - and that includes badly forumulated diets, whether they are keto, WFPB or Weight Watchers. So it is worth doing a periodic self-assessment, just to make sure things are ticking along nicely.