CF is inherited in an autosomal recessive manner. It is caused by the presence of mutations in both copies of the gene for the cystic fibrosis transmembrane conductance regulator (CFTR) protein. Those with a single working copy are carriers and otherwise mostly healthy. CFTR is involved in the production of sweat, digestive fluids, and mucus. When the CFTR is not functional, secretions which are usually thin instead become thick. The condition is diagnosed by a sweat test and genetic testing. Screening of infants at birth takes place in some areas of the world.