MIAMI (CBSMiami) – Parents and schools have worried in recent years about the inclusion of junk food in schools; but a new study said all of that worry is for nothing.

According to a study published in the journal Sociology of Education, a survey of roughly 20,000 middle school kids who attend schools with junk food available to them didn’t gain more weight than students who went to schools where junk food isn’t available.

READ MORE: Opa-locka Hialeah Flea Market Vendors: 'We have to leave like dogs'

The study said that many middle schools sell junk food, especially in schools with a high percentage of poor children.

Several states have tried to crack down on junk food by removing soda machines and other snacks from schools.

READ MORE: Taste Of The Town: Ball And Chain Serving Up Cuban Classics With A Side OF Salsa Music For 8 Decades

The authors of the study said that how kids eat outside of school goes much further in determining obesity than their eating habits during the school day.

Childhood obesity has reached critical levels in the United States.

MORE NEWS: Police Will Be Out In Force In Miami Beach To Ensure A Safe Memorial Day Holiday

Roughly 20 percent of American kids between 6 and 11 are obese and the percentage of kids who are obese and overweight has quadrupled in just the last 25 years, according to Yahoo!.