A community school that operates a drug recovery program in cooperation with a court shall be considered a dropout prevention and recovery community school for purposes of this chapter and shall comply with all enrollment restrictions applicable to such a school.