; and (ii) a written end-product recycling plan that provides for the beneficial use of the material resulting from any anaerobic digestion food waste-to-energy operation with respect to which the loan or grant is made, in a manner that meets all applicable Federal, State, and local laws that protect human health and the environment. (B) Limitation A loan or grant under paragraph (1) may not be used for an anaerobic digester that uses solely manure as undigested biomass. (C) Preference The Secretary shall give preference to loans and grants under paragraph (1) for anaerobic digesters that use primarily nonedible food, crop waste, or nonedible food and crop waste as undigested biomass. (3) Availability Funds made available under paragraph (1) shall remain available until expended. . 504. Grants for composting and anaerobic digestion food waste-to-energy projects (a) In general Subtitle G of the Solid Waste Disposal Act ( 42 U.S.C. 6971 et seq.) is amended by adding at the end the following: 7011. Grants for composting and anaerobic digestion food waste-to-energy projects (a) Grants The Administrator shall establish a grant program to award grants to States eligible to receive the grants under subsection (b)(1) to construct large-scale composting or anaerobic digestion food waste-to-energy projects. (b) Eligible States (1) Eligibility In order to be eligible to receive a grant under this section, a State shall— (A) have in effect a plan to limit the quantity of food waste that may be disposed of in landfills in the State; and (B) provide to the Administrator— (i) a written commitment that the State has read and agrees to comply with the Food Recovery Hierarchy of the Environmental Protection Agency, particularly as applied to apparently wholesome food (as defined in section 22(b) of the Child Nutrition Act of 1966 ( 42 U.S.C. 1791(b) ) that may be provided to or received by the State