Section 68. A person summoned as a trustee in the supreme judicial or superior court, who appears and answers pursuant to this chapter, shall be allowed his costs for travel and term fees, and such further amount for counsel fees and other necessary expenses as the court may allow; if summoned in a district court, he shall be allowed the costs fixed by section twenty-six of chapter two hundred and sixty-one. If there has been a trial between the plaintiff and the alleged trustee upon an issue of fact, the court may award costs to either party.