Whenever a violation of any provision of this chapter by any association or any director, officer, agent, or employee of the association is threatened or impending such that immediate and substantial injury to the association or to its depositors or stockholders will ensue, a court of competent jurisdiction shall, upon suit of the commissioner, issue an injunction restraining the violation.