If anything is recovered or obtained as the result of an action under AS 10.15.200, whether by compromise and settlement or by judgment, the court may award the plaintiff the reasonable expenses of maintaining the action, including reasonable attorney fees, out of the proceeds of the recovery, and may direct the plaintiff to account to the cooperative for the remainder of the proceeds.