All money collected for taxes or assessments under this article shall be kept in a separate fund by the treasurer or other officer of the state agency charged with the safekeeping and disbursement of funds of the state agency, and, upon the written demand of the department, the treasurer or other officer shall pay over to the department all such money in his possession or control and the money shall be applied by the department to the satisfaction of the amount due under the contract.