The parties to a construction contract with a public agency may expressly agree in writing that in any arbitration to resolve a dispute relating to the contract, the arbitrator’s award shall be supported by law and substantial evidence. If the agreement so provides, a court shall, subject to Section 1286.4, vacate the award if after review of the award it determines either that the award is not supported by substantial evidence or that it is based on an error of law.