My unprofessional opinion is that these are both explained by a third variable, excessive consumption of carbohydrates, starches especially. (It also explains the correlation between poor dental health and dementia).
Myopia is known to be promoted by excessive carbohydrate consumption.