; and (ii) shall immediately release any detained alien who is a member of a vulnerable group. (B) Exceptions The Secretary of Homeland Security may detain, pursuant to the Immigration and Nationality Act ( 8 U.S.C. 1101 et seq. ), an alien who is a member of a vulnerable group if the Secretary makes a determination, using credible and individualized information, that the use of alternatives to detention will not reasonably ensure the appearance of the alien at removal proceedings, or that the alien is a threat to another person or to the community. The fact that an alien has a criminal charge pending against the alien may not be the sole factor to justify the detention of the alien. (C) Removal If detention is the least restrictive means of effectuating the removal from the United States of an alien who is a member of a vulnerable group, the subject of a final order of deportation or removal, and not detained under subparagraph (B), the Secretary of Homeland Security may, solely for the purpose of such removal, detain the alien for a period that is— (i) the shortest possible period immediately preceding the removal of the alien from the United States; and (ii) not more than 5 days. (2) Weekly review required (A) In general Not less frequently than weekly, the Secretary of Homeland Security shall conduct an individualized review of any alien detained pursuant to paragraph (1)(B) to determine whether the alien should continue to be detained under such paragraph. (B) Release Not later than 24 hours after the date on which the Secretary makes a determination under subparagraph (A) that an alien should not be detained under paragraph (1)(B), the Secretary shall release the detainee. (g) Protective custody for LGBTQI alien detainees (1) Detainees An LGBTQI alien who is detained pursuant to subparagraph (B) or (C) of subsection (f)(1) may not be placed in housing that is segregated from the general population unless— (A) the alien requests placement in such housing for the protection of the alien