Judges are directed by the terms of the legislation on which the application is made, and also by the Civil Procedure Rules (see Ministry of Justice) and other regulations.
This means that there are some things that the Judge must do and some things that they may do. Judges must act fairly and impartially, and their decisions will be based upon the facts that are proven, the rules that apply to the case and/or the wider social consequences of any decision that they make. Although a judge may strike out a claim if it is defective due to an error, they may also allow some errors to be corrected and allow a case to proceed.