CCP 1876     

Art. 1876.  Court may refuse declaratory judgment

The court may refuse to render a declaratory judgment or decree where such judgment or decree, if rendered, would not terminate the uncertainty or controversy giving rise to the proceeding.