However, where the period of detention is for such a short period, the person is still considered to mainly occupy the dwelling and a disregard applies where the person is:detained under deportation provisions of the Immigration Act 1971detained in a prison, a hospital or other place by a courtdetained under the Mental Health Act 1983 (1984 Scotland)imprisoned, detained or in custody (but not in c