8. A person is not a foster parent or engaged in caring for the purposes of section 23A during any period in respect of which that person is—
(a)not ordinarily resident in Great Britain; or
(b)undergoing imprisonment or detention in legal custody.