If a statute allows costs to a party in an action or proceeding, the costs shall include all of the following:
(a) The premium on a bond reasonably paid by the party pursuant to a statute that provides for the bond in the action or proceeding.
(b) The premium on a bond reasonably paid by the party in connection with the action or proceeding, unless the court determines that the bond was unnecessary.
(Added by Stats. 1982, Ch. 998, Sec. 1.)