What role does the Supreme Court play in amending religious laws?

Examine the Supreme Court's involvement in the amendment of religious laws, focusing on the recent challenges to the Waqf (Amendment) Act.