27-18-711. Motion to discharge writ improperly issued. The defendant may also, at any time either before or after the release of the attached property or before any attachment shall have been actually levied, apply on motion, upon reasonable notice to the plaintiff, to the court in which the action is brought or to a judge thereof that the writ of attachment be discharged on the ground that the same was improperly or irregularly issued.