Any claim for which a lien may be or has been filed and the right to recover therefor under the provisions of this chapter may be assigned by an instrument in writing. Such assignment vests in the assignee all rights and remedies herein given, subject to all defenses that might have been interposed if such assignment had not been made.
N.D.C.C. § 35-27-27