
    Michelle R. Alberts, Respondent, v Richard J. Alberts, Appellant.
   Order unanimously modified on the law and as modified affirmed with costs to defendant, and matter remitted to Supreme Court for further proceedings, in accordance with the following memorandum: Absent a showing of extraordinary circumstances, it was error for Supreme Court to make a temporary custody determination in an ex parte order to show cause. A custody determination, which may drastically affect a child’s welfare, ordinarily should not be based solely on an ex parte application. When defendant’s attorney appeared to object, the court compounded the error by permitting the children, whom the mother had removed from the marital residence pursuant to the ex parte order, to remain with the mother as the primary custodial parent, without conducting a hearing (see, Audubon v Audubon, 138 AD2d 658; Savas v Savas, 127 AD2d 578). We, therefore, modify Supreme Court’s order by deleting the first decretal paragraph and remit the matter to Supreme Court for an immediate hearing before a different Justice on the issue of temporary custody. (Appeal from order of Supreme Court, Erie County, Wolfgang, J. — temporary support.) Present — Callahan, J. P., Denman, Balio, Lawton and Davis, JJ.  