The plaintiff also agrees to advance the money to pay the costs of the seizure mentioned in the complaint, and all the costs connected therewith, including advertising, and if the plaintiff shall not be found liable to pay such costs and charges, so paid by such advance, the money so paid shall be deducted from the amount otherwise awarded, if anything, against him by such final judgment.