Type 1 diabetes is an autoimmune disease in which the immune system attacks and kills off the cells in the pancreas that produce insulin , a hormone that enables people to convert food into energy . � � It affects children , adolescents , and adults .