Judge's ruling was insane. She certainly had the discretion to leave the child with his adoptive parents, and there was likely precedent for this exact situation. Taking him away from his family doesn't make any sense. Poorly written conclusion to an otherwise great episode.