On December 17, 1910, the state bank • examiner took charge of the Commercial Bank, a state bank doing business at Vancouver, acting under the authority of § 3305, Rem. & Bal. Code, now repealed.
Respondent was then county clerk of Clarke county and maintained an ordinary checking account with the bank under the name of John Wilkinson, county clerk of Clarke county, and when the bank was taken in charge, the balance to his credit was $3,502.48.
Up to December 17, the respondent had never been given any security of any kind, but on or within two or three days after that date the bank turned over to respondent a promissory note for $11,000, given to the bank by one Harvey. This seems to have been done at the instance of the president of the bank, and he and the cashier seem to have led the deputy state bank examiner in charge to believe that the possession of this note belonged to respondent as collateral security for his account. Respondent accepted the collateral offered and retained it as security for his account for a little over two weeks, at the end of which time he was called upon to surrender it, and received payment from the deputy bank examiner of his account in full.
*342The examiner continued his possession of the hank and investigation of its affairs for about two months longer, and being then convinced that the bank was insolvent, caused proceedings for the appointment of a receiver to be carried through by the Attorney General. The bank was then duly adjudged insolvent, and appellant was appointed its receiver in March, 1911. Upon his appointment, the receiver investigated the matter, and being convinced that the payment of respondent’s account in full was without authority and an illegal preference, he demanded repayment of the same. Repayment being refused, he began this action in tort to recover as damages the sum of $3,502.48 paid over to respondent, alleging that the respondent and the other defendants named, cooperating and participating together, caused to be assigned, set over, transferred, and delivered to respondent the note heretofore mentioned, and the respondent, participating with them, received the note as and for collateral security for the payment of his account. It was alleged also that the note was a part of the general assets of the bank, and was given and received as above stated with the intent and for the purpose on the part of all the parties to the transaction of wrongfully preferring the respondent, Wilkinson, over other general creditors of the bank. It is also alleged that, in pursuance of the above intent and purpose, the defendants all cooperating and participating, on about January 7, 1911, the other defendants caused to be paid over to respondent the sum of $3,502.48 in full payment of his account and deposit, and that thereupon respondent surrendered the pretended collateral security above mentioned; that it was the intent and purpose on the part of all the defendants, parties to the above transaction, that respondent should be wrongfully preferred to the other general creditors of the bank; that, by reason of the *343foregoing acts and doings of all the defendants, the Commercial Bank of Vancouver was damaged in the sum so taken, and the funds and assets of the bank depleted by that amount. Judgment was demanded for the sum so taken, with interest at the legal rate from January 7,1911.
A demurrer to the complaint on the part of one of the defendants was sustained by the court. The defendant Mohundro died during the pendency of the action and the action continued against respondent alone.
Respondent demurred to the complaint for insufficient facts. His demurrer, after consideration by the court, was overruled. Respondent then answered, denying part of the complaint and admitting the remainder. There was no affirmative defense. On the issues thus made, the court tried the cause without a jury, and made findings of fact in which all the material allegations of the complaint were found true. Conclusions of law and judgment were nevertheless rendered for the respondent.
There was no allegation in the complaint that the assets in the hands of the receiver were insufficient to satisfy the claims of all creditors. The appellant did, however, after the trial of the cause by the court, ask that the proceeding be reopened and that he be permitted to introduce proof to the effect that the assets of the defunct bank were insufficient to pay any more than twenty per cent, or twenty-five per cent in all, of the claims of general creditors. This application was denied by the court for the reason that the court was of the opinion that it would be immaterial to make such proof, because of his conclusion, that, in any event, the respondent was not liable, since the deposit was a deposit by a public officer, as such, of the public funds coming into his hands as county clerk, the deposit *344thereby constituting a trust fund which upon the failure of the bank, respondent was entitled to receive back intact.
There is no statute requiring county clerks to deposit funds in their hands as such in any bank, or requiring any bank to be designated as depositary for such fund. While it is true that the funds deposited by respondent as county clerk of Clarke county implied a notice to the depositary that the funds were public funds and not private funds of the depositor, nevertheless the funds were deposited subject to check as an ordinary account, and, as such, constituted a general and not a special deposit.
It is contended by respondent that the deposit by the county clerk, as such, created it a deposit of county funds, or of public funds belonging to litigants in the court of which respondent was clerk. There is a conflict of opinion among authorities as to whether, in the absence of statute, there exists in any political subdivision a common law right to have its debts paid to it in preference to other creditors when the debtor is insolvent. But as applied to insolvent banks in which deposits of public money have been made, the better rule seems to be that, in the absence of statute or a showing of facts sufficient to create a trust, a claim for public money has no preference over the claims of the general creditors of the bank, but stands on the same footing with them. 3 B. C. L. §182; Note to Page County v. Rose, 8 Ann. Cas. 116, and cases there cited. Ordinarily, public money in the hands of its official custodian without special authority to deposit the same in a bank is a trust fund, and when a bank accepts such money knowing its trust character, the bank becomes a quasi-trustee and the trust character attaches to the fund in the hands of the bank, making it a preferred claim if it has not been so commingled with *345the other funds of the bank as to have lost its identity. Note, same case, and cases cited therein.
In this case the funds were deposited by the county clerk from time to time and checked against from time to time, and were not one special deposit of a trust character, other than that they constituted a trust fund in the hands of the clerk himself. They were evidently carried in the bank commingled with all its other funds, until the bank was closed for liquidation.
When a bank becomes insolvent and is taken over by the public examiner, the assets of the bank become a fund for the payment of the claims of the various creditors, and unless some reason is shown, recognized by law, that entitles one creditor to a preference over the others, they should all be treated alike. If the assets are sufficient in amount, the creditors can be paid in full, but where there are not sufficient funds to pay the just claims of all of the creditors in full, then such fund as there is should be proportioned among such creditors according to the amounts of their respective claims. This rule applies to all bank depositors. City of Sturgis v. Meade County Bank, 38 S. D. 317, 161 N. W. 327; Cavin v. Gleason, 105 N. Y. 256, 11 N. E. 504.
•As a rule, when money is deposited in a bank, title to it passes to the bank. ■ The bank becomes the debtor of the depositor to the extent of the deposit, and to that extent-the depositor becomes the creditor of the bank. Allibone v. Ames, 9 S. D. 74, 68 N. W. 165, 33 L. R. A. 585. Such deposit then constitutes a part of the assets of the bank and, in case of insolvency, belongs to the creditors of the bank in proportion to the amounts of their respective claims. Exceptions to this rule are: First, where money or other thing is deposited with the understanding' that that particular money or thing is to be returned to the depositor; second, where the money or thing deposited is to be used for a specifical*346ly designated purpose; and third, where the deposit itself was wrongful or unlawful. City of Sturgis v. Meade County Bank, supra.
The money involved in this case was deposited by the county clerk subject to his check, without any understanding that the identical money deposited should be returned to him or that it should be used for any specific purpose. It cannot be said that it falls within the third exception to the above rule, that the deposit itself was wrongful or unlawful, for while the clerk was responsible for the fund in his hands, he had a perfect right tp deposit it in bank wherever he pleased, being responsible for the safety of the funds. Phillips v. Yates Center Nat. Bank, 98 Kan. 383, 158 Pac. 23, L. R. A. 1917A 680; State v. McFetridge, 84 Wis. 473, 54 N. W. 1, 998, 20 L. R. A. 223; 3 R. C. L. 182.
We are forced to the conclusion, therefore, that the deposit of respondent in the insolvent bank was not a public or a trust deposit.
The question then arises whether or not the officers in the bank were relieved from responsibility because of the approval of the appropriation of collateral to the security of the fund of the respondent and its reduction thereafter into payment of the deposit. At the time of the delivery of the note as collateral, the bank examiner was in charge of the bank through a deputy. The bank examiner, under the law then in force (Rem. & Bal. Code, §3305), was required, upon taking charge of the bank, to ascertain as soon as possible, by thorough examination into its affairs, its actual condition, and whenever he should become satisfied that the bank could not resume business or liquidate its indebtedness to the satisfaction of all of its creditors, to report the fact of its insolvency to the Attorney General, who was thereupon required to institute proper proceedings in the proper court for the *347appointment of a receiver to take charge of and wind np the affairs and business of the bank for the benefit of its depositors, creditors, and stockholders. At the time of the transaction in question, the bank examiner had not closed the bank, but was in charge of its assets. There was no authority conferred upon him by law to act as agent for the bank or its officers, and his sole authority was to act as agent for the state to examine into the affairs and condition of the bank and report its condition as soon as he could ascertain it. He, of course, had the right to require liquidation of the assets of the bank, but no right to make any contract for the bank or to ratify any contract which had been theretofore made. There had been no prior com tract between the bank or its officers and respondent for the security of the respondent’s funds on deposit. The offering of security by the officers of the bank seems to have been merely voluntary, but for the bona fide purpose of securing a public officer’s deposit. Neither is there any question of the good faith of respondent. He gratefully accepted security and the subsequent payment of his deposit. At that time he was to some extent justified, although he knew that the bank was in the hands of the state bank examiner, by the fact that the state bank examiner had not declared the bank insolvent and applied for a receiver, and did not thereafter for about sixty days. Appellant does not charge respondent with actual bad faith, but charges only that the taking of the funds by him from the hands of the bank examiner was unlawful and wrongful, inasmuch as the deposit was not a trust deposit; that the funds which had theretofore been deposited could not be traced or identified, and were not county or public funds deposited in the bank as a county depositary or deposited with notice that they were county funds; and that, by reason of these proposi*348tions, the transaction between the officers of the bank and the bank examiner on the one hand and respondent on the other constituted an unlawful preference, regardless of the good or bad faith of the transaction, and prima facie damage to the insolvent estate.
These propositions are correct and, as stated in the previous discussion of the trust fund theory of the deposit, there being no such status, respondent had no right to a preference over other creditors of the insolvent. 7 C. J. 629, 643; Brown v. Sheldon State Bank, 139 Iowa 83, 117 N. W. 289; Alston v. State, 92 Ala. 124, 9 South. 732, 13 L. R. A. 659; McLain v. Wallace, 103 Ind. 562, 5 N. E. 911; Otis v. Gross, 96 Ill. 612, 36 Am. Rep. 157; Retan v. Union Trust Co., 134 Mich. 1, 95 N. W. 1006; Southern Development Co. v. Houston & T. C. R. Co., 27 Fed. 344; In re Nichols, 166 Fed. 603; Phillips v. Yates Center Nat. Bank, 98 Kan. 383, 158 Pac. 23, L. R. A. 1917A 680.
This, however, is not an action to set aside a transfer of funds, follow the funds and recover them for the estate, but is an action against respondent and his codefendants for damages for the wrongful taking of the fund. Notwithstanding that the taking of the fund was in law wrongful and unlawful, even in cases arising under the Federal bankruptcy laws, where the procedure against unlawful preferences and preferring debtors to preferred creditors is much more drastic than in this sort of action, it has been generally held that the trustee cannot maintain an action to set aside a preference and avoid a transfer unless it is shown by the complaint that he has not sufficient assets in his hands to satisfy the claims of the debtor. No such showing was made in the complaint, for all that appears there may be money and property enough in the hands of the trustee to pay every claim filed against the debtor. Admitting that the facts stated show the *349transfers to have been fraudulent, still no right to avoid them exists unless it appears that some one was harmed. Having elected to sue for damages, it was incumbent upon appellant to allege and prove a proper measure of damage. The complaint ought to show, and evidence sustain, the amount of the claims filed and the value of the assets in the hands of the trustee, so that the court may determine the necessity of setting aside or recovering the value of the preference. Mueller v. Bruss, 112 Wis. 406, 88 N. W. 229; Deland v. Miller & Cheney Banh, 119 Iowa 368, 93 N. W. 304; Roney v. Conable, 125 Iowa 664, 101 N. W. 505; Seager v. Armstrong, 95 Minn. 414, 104 N. W. 479.
In this case it will be observed that, so far as the complaint is concerned, there may be ample money in the hands of the trustee to satisfy and discharge all the liabilities of the estate, if there be any, which does not appear. This is a fatal defect and the demurrer to the complaint should have been sustained.
However, after the trial had closed but before any decision had been rendered, appellant, realizing the probable fatality of that defect, offered to prove the condition of the estate as has been heretofore stated. This was refused by the trial court for the reason that the trial court was of the opinion that, in any event, the respondent was not liable. We are of a different opinion. The respondent is liable only to the extent of • the damage sustained by the estate. For that reason the rejected proof should have been received, and the pleadings should have been amended or deemed amended and issues formed thereon so that respondent could meet the proof of appellant upon that phase of the matter. It is possible that the estate will not be damaged more than 75 per cent at the most, and possibly less, of the amount turned over by the bank to respond*350ent. At any rate, it is a matter that should be put at issue and proof received to show the true facts.
The judgment will be reversed, and the cause remanded with instructions to the lower court to reopen the case, sustain the demurrer of respondent, or consider all the pleadings amended to conform to the offer of proof (which amounts to a tender of amendment to the complaint on the part of appellant), receive the evidence of appellant under the offer of proof and that of respondent, if any, and render judgment thereon. This determination also will be without prejudice to the respondent to his right to file a claim with the receiver and receive the same dividends as were given to other general depositors.
Ellis, O. J., Chadwick', Main, and Mount, JJ., concur.