Nothing in, or done under the authority of, a law shall be held to be inconsistent with, or in contravention of, this article to the extent that the law in question makes provision— (a) for the imposition of restrictions by order of a court, that are required in the interest of defence, public safety or public order, on the movement or residence within Ghana of any person; or (b) for the imposition of restrictions, by order of a court, on the movement or residence within Ghana of any person either as a result of his having been found guilty of a criminal offence under the laws of Ghana or for the purposes of ensuring that he appears before a court at a later date for trial for a criminal offence or for proceedings relating to his extradition or lawful removal from Ghana; or (c) for the imposition of restrictions that are reasonably required in the interest of defence, public safety, public health or the running of essential services, on the movement or residence within Ghana of any person or persons generally, or any class of persons; or (d) for the imposition of restrictions on the freedom of entry into Ghana, or of movement in Ghana, of a person who is not a citizen of Ghana; or (e) that is reasonably required for the purpose of safeguarding the people of Ghana against the teaching or propagation of a doctrine which exhibits or encourages disrespect for the nationhood of Ghana, the national symbols and emblems, or incites hatred against other members of the community; except so far as that provision or, as the case may be, the thing done under the authority of that law is shown not to be reasonably justifiable in terms of the spirit of this Constitution.