
822 N.E.2d 89 (2004)
354 Ill. App.3d 610
290 Ill.Dec. 807
R. STARR, d/b/a George Ellison Management Company, Plaintiff-Appellee,
v.
Glynnis GAY, Defendant-Appellant.
No. 1-03-2672.
Appellate Court of Illinois, First District, Second Division.
December 30, 2004.
*90 Jon A. Duncan of Armstrong & Associates, P.C., Oak Park, for Appellant.
Jerome Wiener and James R. Griffin of Schain, Burney, Ross & Citron, Ltd., Chicago, for Appellee.
Justice HALL delivered the opinion of the court:
The central issue in this case is whether the commingling prohibition set forth in section 5-12-080(a) of the Chicago Residential Landlord and Tenant Ordinance (Ordinance) (Chicago Municipal Code § 5-12-080(a) (amended November 6, 1991)) is violated when a landlord-seller of a subject property transfers a tenant's security deposit to a purchaser at closing by applying the amount of the deposit toward the property's purchase price and then giving the purchaser a bookkeeping credit against the purchase price equal to the amount of the deposit. We hold that this "credit method" of transferring a tenant's security deposit at closing does not violate the commingling prohibition contained in section 5-12-080(a) of the Ordinance.

BACKGROUND
In 1994, Glynnis Gay (tenant) entered into a written one-year lease agreement with R. Starr, d/b/a George Ellison Management Company (landlord), for lease of an apartment in a 40-unit building in Chicago in which the owner did not reside. *91 Tenant gave landlord a security deposit of $435 when she rented the apartment. The parties renewed the lease four times.
In a letter dated April 13, 1999, sent by certified mail, tenant notified the landlord that pursuant to section 5-12-110(d) of the Ordinance (Chicago Municipal Code § 5-12-110(d) (amended November 6, 1991)), she intended to withhold a portion of her monthly rent unless the landlord corrected 50 defects and violations in her apartment and common areas of the building within 14 days from receipt of the letter. In May 1999, tenant paid landlord reduced rent which tenant claimed reflected the reduced value of the premises due to the landlord's failure to correct 20.5 of the violations.
The following month, the landlord filed a forcible entry and detainer claim to regain possession of tenant's apartment. In July 1999, while the case was still pending, the landlord sold the building in which tenant's apartment was located. On August 12, 1999, tenant filed affirmative defenses and counterclaims to the landlord's forcible entry and detainer claim.
On October 13, 1999, the trial court entered an order granting the landlord's oral motion to dismiss its forcible entry and detainer claim. The matter was then reassigned for further proceedings regarding tenant's counterclaims.
The landlord-purchaser then filed a forcible entry and detainer claim against tenant but shortly thereafter entered into a settlement agreement with tenant in August 2000. As part of the settlement agreement, the landlord-purchaser deposited into an escrow account with tenant's attorney the sum of $4,000; tenant received $1,000 from the escrow deposit. Tenant also agreed to vacate the building on or before August 31, 2000, and waive all claims against the landlord-purchaser relating to her security deposit.[1]
After a protracted exchange of discovery motions, tenant filed her first amended counterclaims against the landlord on October 1, 2002. Count IV of the first amended counterclaims pertained to tenant's allegation that as part of the transaction for the sale of the subject building, the landlord improperly commingled her security deposit with landlord assets in violation of section 5-12-080(a) of the Ordinance, when instead of transferring the security deposit to the landlord-purchaser via check, the landlord transferred the value of the security deposit by applying the amount of the deposit toward the purchase price and then giving the landlord-purchaser a bookkeeping credit against the purchase price equal to the amount of the deposit. Tenant argued that such a transfer improperly commingled her security deposit with landlord assets and thereby constituted a conversion of her deposit.
On May 6, 2003, the trial court denied tenant's motion for partial summary judgment as to count IV, but the court stated that it was willing to give tenant's counsel a Rule 304(a) (155 Ill.2d R. 304(a)) finding regarding the matter. Tenant's counsel accepted the trial court's offer and thereafter consented to landlord's counsel orally moving for partial summary judgment in order to allow the court to render its Rule 304(a) finding.
The trial court then entered an order granting landlord's counsel's oral motion for partial summary judgment as to count IV, ruling as a matter of law that the transfer at issue did not violate section 5-12-080(a) of the Ordinance. As promised, the trial court made a finding that pursuant to Supreme Court Rule 304(a), there was no just reason to delay enforcement or *92 appeal of its order granting partial summary judgment in favor of the landlord as to count IV. Tenant timely appealed after her motion for reconsideration was denied.

ANALYSIS
In ruling on the tenant's motion for partial summary judgment as to count IV, the trial court was required to interpret section 5-12-080(a) of the Ordinance. The same rules that govern the interpretation of statutes apply in construing municipal ordinances. City of East St. Louis v. Union Electric Co., 37 Ill.2d 537, 542, 229 N.E.2d 522 (1967); City of Nameoki v. City of Granite City, 408 Ill. 33, 37, 95 N.E.2d 920 (1950); Sternic v. Hunter Properties, Inc., 344 Ill.App.3d 915, 918, 280 Ill.Dec. 29, 801 N.E.2d 974 (2003). As in the case of a statute, the primary objective in construing an ordinance is to ascertain and give effect to the intent of the lawmaking body as disclosed by the language contained in the ordinance. Reitman v. Village of River Forest, 9 Ill.2d 448, 451, 137 N.E.2d 801 (1956).
Interpreting or construing a municipal ordinance is a matter of law for the trial court and is appropriate for summary judgment. See Young v. Village of Glen Ellyn, 120 Ill.App.3d 692, 697, 76 Ill.Dec. 483, 458 N.E.2d 1137 (1983) (holding that the construction of a municipal ordinance is a matter of law). The purpose of summary judgment is not to try a question of fact but to determine whether a genuine issue of material fact exists. Gilbert v. Sycamore Municipal Hospital, 156 Ill.2d 511, 517, 190 Ill.Dec. 758, 622 N.E.2d 788 (1993). Summary judgment is an efficient means of disposing of litigation but it is also a drastic measure, and therefore, should only be employed when the right of the moving party is clear and free from doubt. Gilbert, 156 Ill.2d at 518, 190 Ill.Dec. 758, 622 N.E.2d 788. This court reviews the grant of summary judgment de novo. Morris v. Margulis, 197 Ill.2d 28, 35, 257 Ill.Dec. 656, 754 N.E.2d 314 (2001).
In this case, we find that since a landlord-seller's "credit method" of transferring a tenant's security deposit at closing does not violate the commingling prohibition contained in section 5-12-080(a) of the Ordinance, no genuine issue of material fact exists as to this issue, and therefore, the trial court did not err in granting the landlord's motion for partial summary judgment as to count IV.
A security deposit has been defined as money a tenant deposits with a landlord as security for the tenant's full and faithful performance of the lease terms. Beal Bank, S.S.B. v. Airport Industrial Ltd. Partnership, 74 Conn.App. 460, 463, 812 A.2d 866, 868 (2003). Under the terms of a lease agreement, a security deposit remains the tenant's property which the landlord holds in "trust" for the tenant's benefit subject to the tenant fulfilling its obligations under the lease. Beal Bank, S.S.B., 74 Conn.App. at 463, 812 A.2d at 868; see also In re McGee, 353 F.3d 537, 540 (7th Cir.2003) (concluding that pursuant to section 5-12-080(a), landlords hold tenant security deposits as fiduciaries for purposes of section 523(a)(4) of the Bankruptcy Code (11 U.S.C. § 523(a)(4) (2000)) pertaining to exceptions to discharge of debt in bankruptcy).
Security deposit provisions like section 5-12-080(a) are designed to keep tenant monies out the reach of creditors of landlords and prevent risks inherent in commingling, such as a landlord's intentional or inadvertent personal use of tenant funds contained in a commingled account.[2] See, e.g., Neihaus v. Maxwell, 54 *93 Mass.App.Ct. 558, 561-62, 766 N.E.2d 556, 559 (2002).
Section 5-12-080(e) of the Ordinance (Chicago Municipal Code § 5-12-080(e) (amended November 6, 1991)) authorizes a landlord of residential property holding tenants' security deposits to transfer those deposits along with accrued interest to the new owner upon sale of the property. However, this section does not specify a particular method for transferring a tenant's security deposit during such a sale.
Tenant contends that the "credit method" of transferring her security deposit to the landlord-purchaser upon sale of the property violated the commingling prohibition contained in section 5-12-080(a) of the ordinance. Specifically, tenant maintains that the landlord breached its fiduciary duty to her and violated section 5-12-080(a)'s commingling prohibition when the landlord transferred the value of her and other tenants' security deposits to the landlord-purchaser by applying the aggregate amount of the deposits ($22,225) toward the purchase price of the subject property and then giving the landlord-purchaser a credit against the purchase price equal to the amount of the deposits. Tenant argues that this method of transfer exposed her security deposit to creditor claims of the landlord and landlord-purchaser and amounted to a failure to keep her deposit in a separate federally insured account. Tenant's contentions are meritless.
It has been determined that there are a number of methods, including the "credit method," that landlords can use to properly transfer a tenant's security deposit. See S. Saltz, Nonresidential Security Deposits, 27 Real Est. L.J. 225, 231 (1999) ("transfer of security deposits can be accomplished by the transfer of separate accounts in which non-commingled security deposits are held, by the transfer of other assets which are deposited as the security deposit, or by a credit against the purchase price in the amount of commingled security deposits"); R. Graham, The Closing, RPST FL-CLE 4-1, § 4.45 (1997) ("A credit to the buyers for the amount of tenant security deposits has the effect of reducing the cash to the sellers and giving the buyers the money that must be refunded to the tenant at the end of the term").
One court has found that a security deposit transfer similar to the one at issue in this case did not constitute improper commingling or conversion. See Tow v. Maidman, 56 Misc.2d 468, 288 N.Y.S.2d 837, 839-40 (1968) (landlord's transfer of tenants' security deposits to purchaser at time of closing by extending a credit against purchase price of building equal to the amount of the deposits did not constitute an improper commingling or conversion of the deposits, where the deposits were not depleted during the transaction and the purchaser acknowledged holding the deposited funds as security).
In the instant case, as in Tow, there is no indication that the tenant's security deposit was depleted during the transfer. Furthermore, the momentary use of the value of the tenant's security deposit as a credit during closing did not expose the deposit to attachment by creditors of the landlord or landlord-purchaser.
Attachment is a pretrial remedy wherein a defendant's property is seized and held until the rights of the parties are *94 determined in the principal action. Cozart v. Cozart, 258 Ill.App.3d 848, 850, 197 Ill.Dec. 667, 631 N.E.2d 889 (1994). The purpose of attachment is to permit a creditor to secure and hold a debtor's property to satisfy a debt which the creditor hopes to prove. Old Kent Bank v. Stoller, 254 Ill.App.3d 1085, 1092, 194 Ill.Dec. 149, 627 N.E.2d 265 (1993).
A landlord's "credit method" of transferring a tenant's security deposit at closing does not suddenly render the deposit attachable landlord property. Prior to the transfer, a tenant's security deposit is held in trust by the landlord, and after the transfer, the deposit is then held in trust for the tenant's benefit by the new owner, since the new owner received a credit against the purchase price for the amount of the deposit. See, e.g., Tuteur v. P. & F. Enterprises, Inc., 21 Ohio App.2d 122, 134, 50 O.O.2d 219, 255 N.E.2d 284, 292 (1970) (subsequent purchaser has obligation to return security deposit to tenant where purchaser expressly assumes obligation or receives credit against purchase price for the amount of the deposit).
We hold that a landlord's "credit method" of transferring a tenant's security deposit at closing does not violate the commingling prohibition contained in section 5-12-080(a) of the Ordinance. A real estate closing statement that includes a credit in the amount of a tenant's security deposit complies with section 5-12-080(a) of the Ordinance.
As a final note, we reject the landlord's argument that his transfer of tenant's security deposit at closing could not have violated section 5-12-080(a) of the Ordinance, on the ground that at the time he was no longer the "landlord." It is true that a voluntary sale of realty by a landlord terminates the relation of landlord and tenant as between the original lessor and tenant. Bellows v. Ziv, 38 Ill.App.2d 342, 351, 187 N.E.2d 265 (1962). However, the landlord has failed to cite any legal authority holding that, during closing, a landlord loses his status as a landlord under the ordinance. Moreover, pursuant to section 5-12-080(e) of the Ordinance, a transferor remains jointly and severally liable for the tenant's security deposit after sale of the premises, unless and until such transferor transfers said deposit and satisfies the notice requirements of the section. There is nothing in the record indicating that the landlord complied with the notice requirements of section 5-12-080(e) of the Ordinance.
Accordingly, for the reasons set forth above, we affirm the judgment of the circuit court of Cook County granting the landlord's oral motion for partial summary judgment as to count IV of tenant's first amended counterclaims.
Affirmed.
HOFFMAN and SOUTH, JJ., concur.
NOTES
[1]  The landlord-purchaser is not a party to this appeal.
[2]  Section 5-12-080(a) of the Ordinance provides in relevant part as follows:

"A security deposit and interest due thereon shall continue to be the property of the tenant making such deposit, shall not be commingled with the assets of the landlord, and shall not be subject to the claims of any creditor of the landlord or of the landlord's successors in interest, including a foreclosing mortgagee or trustee in bankruptcy." Chicago Municipal Code § 5-12-080(a) (amended November 6, 1991).
