Attorney Fees to the Prevailing Party in a Contract Action

Civil Code section 1717, subdivision (a), authorizes the trial court to award reasonable attorney fees to the prevailing party in a contract action if the contract specifically provides for an award of such fees. "The party prevailing on the contract shall be the party who recovered a greater relief in the action on the contract." ( 1717, subd. (b)(1).) However, section 1717, subdivision (b)(2), provides, "Where an action has been voluntarily dismissed or dismissed pursuant to a settlement of the case, there shall be no prevailing party for purposes of this section." Section 1717, subdivision (b)(2), "overrides or nullifies conflicting contractual provisions, such as provisions expressly allowing recovery of attorney fees in the event of voluntary dismissal or defining 'prevailing party' as including parties in whose favor a dismissal has been entered." (Santisas v. Goodin (1998) 17 Cal.4th 599, 617 (Santisas).) Contract claims may be joined with other causes of action that do not sound in contract. "If the voluntarily dismissed action also asserts causes of action that do not sound in contract, those causes of action are not covered by section 1717, and the attorney fee provision, depending upon its wording, may afford the defendant a contractual right, not affected by section 1717, to recover attorney fees incurred in litigating those causes of action." (Santisas, supra, 17 Cal.4th at p. 617.) Because section 1717, including the definition of prevailing party, is no longer controlling, the attorney fee provision in the parties' agreement is relevant to determining both "whether the party seeking fees has 'prevailed' within the meaning of the provision and whether the type of claim is within the scope of the provision." (Exxess Electronixx v. Heger Reality Corp. (1998) 64 Cal.App.4th 698, 708.) "If the contract allows the prevailing party to recover attorney fees but does not define 'prevailing party' or expressly either authorize or bar recovery of attorney fees in the event an action is dismissed, a court may base its attorney fees decision on a pragmatic definition of the extent to which each party has realized its litigation objectives, whether by judgment, settlement, or otherwise." (Santisas, at p. 622; see Donner Management Co. v. Schaffer (2006) 142 Cal.App.4th 1296, 1310 "In the absence of legislative direction in the attorney fees statute, the courts have concluded that a rigid definition of prevailing party should not be used. Rather, prevailing party status should be determined by the trial court based on an evaluation of whether a party prevailed '"on a practical level . . . ."'".)