
    In re WINGSPREAD CORPORATION, et al., Debtors. PANDORA INDUSTRIES, INC., Appellant, v. PARAMOUNT COMMUNICATIONS INC., f/k/a Gulf & Western Inc. and Harold Young, Trustee, Appellees.
    Bankruptcy Nos. 87B10619 (TLB) to 87B10630 (TLB).
    No. 91 Civ. 1926 (PNL).
    United States District Court, S.D. New York.
    Sept. 29, 1992.
    
      Daniel A. Zimmerman, New York City, for appellant Pandora Industries, Inc.
    Weil, Gotshal & Manges (Marcia L. Gold-stein, Brian S. Rosen, Kevin W. Barrett, Roger F. Assad, of counsel), for appellee Paramount Communications Inc.
   OPINION AND ORDER

LEVAL, District Judge.

Pandora Industries, Inc. appeals the Bankruptcy Court’s decision requiring it to reimburse Paramount Communications Inc. for monies advanced by Paramount to a lessor to cure defaults in leases held by Pandora.

BACKGROUND

On September 15, 1983, Kayser Roth Corporation, a former wholly owned subsidiary of Paramount Communications Inc., entered into three real property leases with the lessor, One Dow Court, Inc (“Dow”). Each of these leases was essentially identical except as to the site leased and the amount of rent. Simultaneous to the execution of the leases, Paramount executed three guaranties of its subsidiary’s obligation as lessee.

In September 1983, Kayser Roth assigned its interest in the leases to its affiliate, Gulfkay, Inc. At the same time, Paramount restated its guaranties of the lessee’s obligations. In June 1985, Gulfkay assigned its interest as lessee under the leases to PSI, one of the Debtors in the bankruptcy proceedings. The assignments provided that they “shall not release Assignor [Gulfkay] from any of its obligations under the lease including the payment of all rents, additional rents and other payments reserved thereunder_” Paramount again restated its guaranties of the lessee’s obligations. Thereafter, in September, 1985, Paramount sold all of the stock of Gulfkay and Kayser-Roth and assumed their liabilities.

On April 8, 1987, the Debtors (including the assignee of Gulfkay’s lease) filed voluntary petitions for relief under chapter 11 of the Bankruptcy Code. On that same day, the lessor Dow sent three letters to Paramount asserting that each of the leases was in default. Paramount acknowledged its guaranties but expressed concern that if it honored the guaranties by paying Dow the outstanding rent, the Debtors might later exercise their option under bankruptcy law to assume the executory portion of the leases and contend that no cure was necessary because no defaults existed. Seeking to avoid this risk, Paramount entered into three agreements with Dow (“the May 21 letters”) providing that Paramount would advance monies to Dow to cover the amounts owed by the Debtors, but that the defaults under the leases would remain outstanding. The agreements further provided that in the event the Debtors assumed the leases and cured the defaults by payment of the arrearages, Dow would turn those payments over to Paramount as repayment for the monies previously advanced. In the event that the Debtors rejected the lease, Dow would apply the amounts advanced to Paramount’s obligations. Under these agreements, in May 1987, Paramount advanced Dow an amount equal to the rental arrearage under the leases.

By motion dated April 8, 1988, the Debtors sought to assume the executory lease agreements and assign them to appellant Pandora. Paramount objected to the motion on the basis that the defaults in the leases had not been cured.

As all parties were eager to conclude the Debtors’ assignment of the leases to Pandora, it was agreed that Pandora would post a letter of credit at closing in the amount of $123,791 in favor of Paramount, pending and subject to the later determination of Paramount’s cross-motion for reimbursement of its advances. By order dated April 26, 1988, amended and restated on May 5, 1988, Judge Brozman approved the sale.

By order dated October 3, 1988, the bankruptcy court converted the cases to chapter 7. Thereafter, Paramount moved for summary judgment, seeking to recover the amount necessary to cure the continuing defaults under the leases. Pandora and the Trustee cross-moved for summary judgment.

Judge Brozman granted Paramount’s motion for summary judgment and denied Pandora’s and the Trustee’s cross-motions for summary judgment. The Bankruptcy Court held that the payments made by Paramount to the lessor subrogated Paramount to the rights of the lessor against the Debtor as lessee and that such rights of subrogation permitted Paramount to demand that the Debtor cure all defaults relating to the leases that Paramount had paid for the debtor. Pandora, the assignee of the Debtors’ interest as lessee of its assumed leases, appealed.

DISCUSSION

A bankruptcy court’s conclusions of law are subject to de novo review. In re Ionosphere Clubs, Inc., 922 F.2d 984, 988-99 (2d Cir.1990). Taking the facts in the light most favorable to Pandora, this court must determine whether there is no genuine issue of material fact and whether Paramount is entitled to judgment as a matter of law.

A debtor in possession may assign an unexpired lease only if it assumes such lease in accordance with § 365(b) of the Bankruptcy Code, which provides that

“if there has been a default in an ... unexpired lease of the debtor, the trustee may not assume such ... lease unless, at the time of assumption of such ... lease, the trustee — (A) cures, or provides adequate assurance that the trustee will promptly cure, such default; (B) compensates, or provides adequate assurance that the trustee will promptly compensate, a party other than the debtor to such ... lease, for any pecuniary loss to such party resulting from such default. ...”

11 U.S.C. § 365(b). Courts have held that a right to immediate cure, such as that provided for in § 365, gives rise to a priority administrative expense under § 507(a)(2). See LJC Corp. v. Boyle, 768 F.2d 1489, 1494 n. 6 (D.C.Cir.1985); In re Monroe Well Serv., Inc., 83 B.R. 317 (Bkrtcy.E.D.Pa.1988).

The parties to this appeal have never disputed that, in accordance with § 365(b), Dow as lessor would have had (if Paramount had not paid Dow) the right to compel the Debtors to cure all defaults and compensate Dow for pecuniary loss as a condition to the Debtors’ assumption of the leases. The question on this appeal is whether Paramount may assert these same rights pursuant to § 509(a) of the Bankruptcy Code which governs “Claims of Co-debtors.” Section 509(a) provides in pertinent part that

an entity that is liable with the debtor on, or has secured, a claim of a creditor against a debtor, and that pays such claim, is subrogated to the rights of such creditor to the extent of such payment.

11 U.S.C. § 509(a).

Courts have divided on the relation between § 509 subrogation and the more familiar equitable doctrine of subrogation. The Ninth Circuit has stated that “[w]hen a bankruptcy court adjudicates a dispute arising from a contract claim, it must apply state law unless the bankruptcy code provides otherwise.” In re New England Fish Co., 749 F.2d 1277, 1280 (9th Cir.1984) (emphasis added). Professing fidelity to this principle, some courts have held that, given the provision of § 509, the equitable doctrine of subrogation should not apply. See Creditor’s Committee v. Massachusetts Department of Revenue, 105 B.R. 145, 154 (D.Mass.1989) (§ 509 clearly controls subrogation under the bankruptcy code); In re Cooper, 83 B.R. 544, 546 (Bkrtcy.C.D.Ill.1988) (“The right of a co-debtor to subrogate under the Code is a federally created right. The right neither refers to nor is based on state law.”). Other courts have held that a party asserting the right to subrogation under § 509 must satisfy the same prerequisites as those required by the doctrine of equitable subro-gation. See, e.g., In re Kaiser Steel Corp., 89 B.R. 150, 152 (Bkrtcy.D.Colo.1988). And still other courts have found that § 509 provides an additional, but not exclusive, remedy in bankruptcy. See, e.g., In re Spirtos, 103 B.R. 240 (Bkrtcy.C.D.Cal.1989). Given this uncertain relation, I will consider both § 509 and the doctrine of equitable subrogation in reaching my decision.

Relying on both state and federal law, Pandora argues that the bankruptcy court erred on three points, each of which provides a sufficient basis for vacation. First, Pandora argues that Paramount does not have standing to assert a right to subrogation because the advances made by Paramount did not constitute “payments.” Second, Pandora argues that subrogation is not available to Paramount because Paramount advanced funds to satisfy its own primary liability, rather than the Debtors’ liability. Finally, Pandora argues that the bankruptcy doctrine of equity of distribution precludes Paramount from using § 509 subrogation to gain priority for its claim.

A. The Question of Payment

Pandora argues that Paramount does not have standing to assert a subrogation claim under the Bankruptcy Code because Paramount did not pay the default. Pandora argues that instead, pursuant to the May 21 letters, Paramount merely advanced monies sufficient to cover the default. Given the May 21 arrangement, Pandora argues that Dow, not Paramount, had a claim for pre-petition rents, but Dow failed to assert that claim.

In making this argument, Pandora relies on a literal reading of § 509(a) of the Code, which provides that

“... an entity that is liable with the debtor on ... a claim of a creditor against the debtor, and that pays such claim, is subrogated to the rights of such creditor to the extent of such payment.”

11 U.S.C. § 509(a) (emphasis added). Pandora also relies on New York cases holding that a potential subrogee has no cause of action until it has made payment in full to the obligee. See, e.g., Ross v. Pawtucket Mut. Ins. Co., 13 N.Y.2d 233, 235, 246 N.Y.S.2d 213, 195 N.E.2d 892 (1963).

I conclude that the Bankruptcy Court was correct in finding that Paramount had made “payment” within the meaning of the subrogation rule. Pandora cites no authority for its assertion that payment in a technical sense is required to subrogate a claim, under either § 509 or the doctrine of equitable subrogation. Indeed, some of the cases relied on by Pandora appear to refute this proposition. See, e.g., Salzman v. Holiday Inns, Inc., 48 A.D.2d 258, 369 N.Y.S.2d 238, 243 (4th Dept.1975) (“The essential element of subrogation is that the party must have made payment on, or had its funds or other property applied to discharge, another’s obligation.”); American Surety Co. v. National Bank, 17 F.2d 942 (S.D.Ohio 1927) (“A surety liable only for part of a debt does not become subro-gated to collateral, or to remedies available to the creditor, unless he pays the whole debt or it is otherwise satisfied.”). The Ninth Circuit has explicitly held that a collateralized assignment constitutes payment under § 509(a). See Feldhahn v. Feldhahn, 929 F.2d 1351, 1354 (8th Cir.1991). The secondary authorities agree. See Am. Jur.2d Subrogation § 29 (1974) (“Payment of the debt need not necessarily be made in money to entitle the party making the payment to subrogation. Whatever discharges the liability and is accepted as payment is sufficient.”); 83 C.J.S. Subrogation § 48(a) (1953) (“It is immaterial in what way a surety satisfied a debt provided he was discharged from liability to his creditor....”); Black’s Law Dictionary 1016 (5th ed. 1979) (defining “payment” as a “discharge of an obligation or debt”).

A more practical definition of “payment” is consistent with the well-established principle that in proceedings to determine the rights of parties against a bankruptcy estate the bankruptcy court as a court of equity may look through the form to the substance in determining the true nature of the transaction in question. Pepper v. Litton, 308 U.S. 295, 305, 60 S.Ct. 238, 244, 84 L.Ed. 281 (1939). The May 21 letters show that the “advance” was in substance a payment. Under the letters, Paramount paid Dow a sum equal to the lease defaults and, in turn, Dow released Paramount from obligation for the defaults. Dow had no obligation to pay back any portion of the “loan” if Dow’s claims against the Debtors were denied in the bankruptcy proceeding. Furthermore, Paramount admitted in the letters that Dow had a valid claim under the guaranty. Paramount offered the “loan” to satisfy this obligation. The sole reason for characterizing the payment as a “loan” was to prevent the Debtor from obtaining an undeserved windfall. “Despite the reference to the transaction as a ‘loan,’ there can be no genuine question that the settlement agreement was a payment for the obligations [iinder the lease].” Creditor’s Committee, 105 B.R. at 156.

The numerous decisions relied on by Pandora are not in conflict with this conclusion. Some of the cases involved situations in which no payments or advances were made. See Krause v. American Guar. & Liab. Ins. Co., 22 N.Y.2d 147, 292 N.Y.S.2d 67, 239 N.E.2d 175 (1968); Ross, 13 N.Y.2d 233, 246 N.Y.S.2d 213, 195 N.E.2d 892. Others are distinguishable as involving situations in which the debt was not discharged in full. See American Surety Co. v. Gerold, 255 A.D. 285, 7 N.Y.S.2d 447 (1st Dept.1938); Hanlon v. Union Bank of Medina, 247 N.Y. 389, 391, 160 N.E. 650 (1928) (surety on mortgage may insist on subrogation to creditor’s title to collateral only when the creditor has been reimbursed “in full”); American Surety Co. v. Palmer, 240 N.Y. 63, 147 N.E. 359 (1925) (surety company that delivered note of third party to trust company to cover “some” of loss did not become subrogated to the claim against the third party upon delivery of the note); McGrath v. Carnegie Trust Co., 221 N.Y. 92, 95, 116 N.E. 787 (1917) (a creditor may not be required to surrender any part of his collateral until payment has been made “in full”).

Nor are cases involving the insurance practice of “loan receipts” in conflict with the conclusion that Paramount has satisfied the payment requirement. It is true that courts have held that such advances are loans, and thus the insurer was not subrogated. See, e.g., Luckenbach v. W.J. McCahan Sugar Refining Co., 248 U.S. 139, 39 S.Ct. 53, 63 L.Ed. 170 (1918); R.J. Enstrom Corp. v. Interceptor Corp., 520 F.2d 1217 (10th Cir.1975). But these cases do not involve a question of standing to assert subrogation rights in a bankruptcy case. Instead, they involve an arrangement developed by the insurance industry to prevent disclosure to a jury of the fact of insurance and to avoid the antipathy juries are thought to have toward insurance companies. See 6A Wright, Miller & Kane, Federal Practice and Procedure § 1546, at 354 (1990). In any event, even in the insurance context, courts have in some circumstances looked behind the agreements. If the loan is viewed as a sham and as actually constituting payment of the insured’s claim, courts have held that the insurer is subrogated and must sue in its own name. See, e.g., American Dredging Co. v. Federal Insurance Co., 309 F.Supp. 425 (S.D.N.Y.1970); see also Wright, Miller & Kane, § 1546, at 358-60.

B. Paramount’s Own Liability to Dow

Pandora’s second contention is that Paramount is not entitled to subrogation because its payments to Dow were made on its own primary liability, rather than the liability of the Debtors.

An essential prerequisite to the right of equitable subrogation is that the person seeking subrogation must have made a payment of another’s obligation. “A person’s payment of his own debt rather than of another’s obligation does not entitle the person to subrogation.” 57 N.Y.Jur. Subrogation § 8; see also In re Kaiser Steel Corp., 89 B.R. 150 (Bkrtcy.D.Colo.1988); In re Eble, 14 B.R. 11 (Bkrtcy.W.D.N.Y.1981); Pathe Exchange, Inc. v. Bray Pictures Corp., 231 A.D. 465, 247 N.Y.S. 476, 481 (1st Dept.1931); People ex rel. McMillan v. Board of Supervisors of Cayuga County, 136 N.Y. 281, 32 N.E. 854 (1892).

Several courts have held that the language of § 509 also requires such a limitation. Section 509(a) of the Bankruptcy Code is applicable only where an entity is “liable with the debtor on, or has secured, a claim of a creditor against the debtor, and that pays such claim ...” 11 U.S.C. § 509(a) (emphasis added). “[T]he requirement that plaintiffs have paid the claim of the debtor is a requirement for secondary liability_” In re Carley Capital Group, 119 B.R. 646, 648 (W.D.Wisc.1990). Some courts have also held that this principle has been codified in § 509(b)(2), which provides that an entity may not be subro-gated to the rights of a creditor if, “as between the debtor and such entity, such entity received the consideration for the claim held by such creditor.” 11 U.S.C. § 509(b)(2). This section is “designed to prevent a person who received the consideration (e.g. the loan proceeds) from the creditor from being subrogated to the creditor’s rights against a guarantor, surety, accommodation maker or similar party after the debtor has satisfied his own obligations.” In re Valley Vue Joint Venture, 123 B.R. 199, 205 (Bkrtcy.E.D.Va.1991); see also In re Russell, 101 B.R. 62, 65 (Bkrtcy.W.D.Ark.1989); In re Trasks’ Charolais, 84 B.R. 646, 651 (Bkrtcy.D.S.D.1988).

Pandora argues, under two theories, that Paramount is primarily liable to Dow. First, Pandora argues that Paramount is primarily liable as a principal obligor, based on Paramount’s assumption of its subsidiaries’ obligations, which, under the terms of the lease, survived the assignment to the Debtors. See In re Tidus, 4 F.2d 558, 559 (D.Del.1925); Rauch v. Circle Theatre, 176 Ind.App. 130, 374 N.E.2d 546, 549-50 (1978); Viera v. Soto, 240 F.Supp. 541, 542 (D.V.I.1965).

Second, Pandora argues that Paramount is primarily liable through its guaranties and restated guaranties executed on assignment of the lease. Pandora relies on two old cases holding that a guaranty of one’s own obligations is an original, not a collateral obligation. See Jones v. Newton, 29 N.Y.S. 1023, 1026 (1st Dept.1894); Kernochan v. Murray, 111 N.Y. 306, 309, 18 N.E. 868 (1888).

I agree with Judge Brozman that Paramount’s liability does not preclude its sub-rogation to Dow’s claim. It is true that Paramount was directly liable to Dow, both on its guaranty and on its assumptions of the obligations of the “Tenant.” But the relevant question in the subrogation context is not simply whether the party was directly liable, but rather whether its payment was used to satisfy another’s obligation. The question is sometimes conceived as one of “ultimate” liability — a question that can be answered by determining which of the liable parties received the consideration. See 124 Cong.Rec. H11,095 (daily ed. Sept. 28, 1978) and 124 Cong.Rec. 17, 411-12 (daily ed. Oct. 6, 1978), reprinted in 1978 U.S.Code Cong. & Admin.News 5787, 6452 and 6521 (“Section 509(b)(2) reiterates the well-known rule that prevents a debtor that is ultimately liable on the debt from recovering from a surety or a co-debtor.”).

Thus, “as between the assignee and the lessee, the assignee bears the primary liability for rent accruing subsequent to the assignment.” Rauch, 374 N.E.2d at 550. See also In re Trasks’ Charolais, 84 B.R. at 649; In re Alloway, 37 B.R. 420, 424 (Bankr.E.D.Pa.1984); Restatement of Property § 16.1(1)(a) & cmt. c (2d ed. 1977); Hamlen v. Rednalloh Co., 291 Mass. 119, 197 N.E. 149, 152, 153 (1935). See generally 83 C.J.S. Subrogation § 54; 49 Am. Jur.2d Landlord and Tenant § 442 at 445 (1970). Cf. In re Bugos, 760 F.2d 731, 734-35 (7th Cir.1985) (co-tenant was subrogated to rights of seller against the other co-tenant). In accordance with these authorities, once the Debtor had taken the assignment of Gulfkay’s interest as lessee, the Debtor was the entity receiving the consideration (in the form of occupancy) and was the primary obligor. This was not altered by the fact that the lessee had contractual rights directly against Paramount as well, for Paramount was not receiving the benefit of the lease. Paramount’s payment of the Debtors’ obligation gave Paramount entitlement to subrogation.

The satisfaction of a guaranty similarly entails satisfaction of another’s obligation. See In re Carley Capital Group, 119 B.R. 646, 648 (W.D.Wisc.1990) (guaranty is obligation “to pay in the event that the other does not”); In re Kaiser Steel Corp., 89 B.R. at 153 (obligation of guarantor depends on existence of primary obligation on part of guarantor’s principal running to principal’s creditor); In re Sensor Systems, Inc., 79 B.R. 623, 626 (Bankr.E.D.Pa.1987) (“guarantor” is clearly within the scope of § 509).

C. Subrogation of the Creditor’s Right to Priority

Pandora’s final argument is that the doctrine of equity of distribution precludes Paramount from obtaining priority for the reimbursement of its payment.

The general policy of the Bankruptcy Code is “to distribute assets of the estate equally to creditors_” Joint Industry Board of Elec. Indus. v. United States, 391 U.S. 224, 228, 88 S.Ct. 1491, 1494, 20 L.Ed.2d 546 (1968). Given this presumption, “statutory priorities are narrowly construed.... If one claimant is to be preferred over others, the purpose should be clear from the statute.... ” Trustees of Amalgamated Ins. Fund v. McFarlin’s, Inc., 789 F.2d 98, 100-101 (2d Cir.1986).

Pandora argues that § 365 contains no such clear priority. Under Pandora’s reading, § 365 does not purport to create a category of priority administrative expenses available to any creditor — such priority expenses are confined to §§ 507(a)(1) and 503(b)(1)(A). Instead, Pandora argues, § 365 creates a priority that only the lessor could exercise. See In re Grayhall Resources, Inc., 63 B.R. 382, 385 (Bkrtcy.D.Colo.1986); In re Harry C. Partridge, Jr. & Sons, Inc., 43 B.R. 669, 671 (Bkrtcy.S.D.N.Y.1984) (Congress intended § 365 to protect lessors). Pandora also relies on Congress’ failure to provide specifically for subrogation in the context of § 365(b).

The authorities relied on by Pandora are not dispositive. Neither the legislative history nor the cases cited by Pandora involve subrogees. While Congress undoubtedly did intend § 365 as a protection for lessors, this does not prove a negative inference with respect to a subrogee of a lessor.

The authorities ignored by Pandora are dispositive. Under the doctrine of subrogation, a subrogee is entitled to assert any priority or special right of the subrogor. 83 C.J.S. Subrogation § 54(d)(2); Shropshire, Woodliff & Co. v. Bush, 204 U.S. 186, 27 S.Ct. 178, 51 L.Ed. 436 (1907); Standard Oil Co. v. Kurtz, 330 F.2d 178 (8th Cir.1964); In re Supreme Plastics, Inc., 8 B.R. 730 (N.D.Ill.1980). Indeed, § 509 provides that the co-debtor is subrogated to the “creditor’s rights,” not just the creditor’s claim. Congress’ provision of subrogation rights in § 509 eliminated any need to provide for subrogation in specific contexts. And § 507(d), which specifically sets forth those claims for which the subrogee is not entitled to priority status, does not include § 507(a)(2), the section under which Paramount’s claims are afforded priority status. “If Congress had intended that priority status not run with these claims, it could have so provided as it did for other sorts of claims. In fact, the legislative history expressly indicates that priority for administrative claims would be transferred to the subrogee. 124 Cong.Rec.H. 11,095 (Sept. 28, 1978); S. 17,-411 (Oct. 6, 1978).” In re Wingspread Corp., 116 B.R. 915 at 931-32 (Bankr.S.D.N.Y.1990); see also In re United States Lines, Inc., 79 B.R. 542, 550 (Bankr.S.D.N.Y.1987); 3 Collier on Bankruptcy ¶ 509.02, at 509-07 (15th ed. 1980). Cf. In re Waite, 698 F.2d 1177 (11th Cir.1983) (subrogees have standing to assert subro-gor’s right to object to discharge of debt- or’s obligation to subrogor).

Finally, it is worth noting that the Debtors’ other creditors are not harmed by Paramount’s assertion of Dow’s right to priority. As the Restatement of Restitution observed with respect to the right of subro-gees to step into the shoes of priority creditors and ahead of other creditors, “[t]he other creditors have no ground for objection, since they are thereby placed in no worse position than that which they would have occupied if the claim had not been paid.” Restatement of Restitution § 162 cmt. f. In the instant case, if Paramount had not paid Dow, Dow would have been entitled to cure the defaults under the leases.

I conclude that the Bankruptcy Court correctly held that the doctrine of equitable subrogation does not preclude Paramount’s subrogation to the priority status of Dow’s claim. Dow would have been entitled to receive cure of the defaults as a priority administrative claim under the lease.

CONCLUSION

The decision of the Bankruptcy Court is affirmed.

SO ORDERED. 
      
      . At the time the parties originally entered into the leases, Paramount was known as Gulf & Western Industries, Inc., while Dow was known as Pandora Industries, Inc., the same name as is now used by its lessee, the appellant. To diminish the confusion, this opinion refers to the parties by their current names.
     
      
      . The guaranties provide, in pertinent part, that Paramount "for itself, its successors and assigns does hereby unconditionally guarantee to Lessor, that the Lessee will faithfully and punctually observe and perform each and all of the Lessee’s obligations under the Lease, including but not limited to the payment of all rent, taxes, insurance and other monetary sums when due.... This Guaranty shall be binding upon the successors and assigns of the Guarantor ... and shall inure to the benefit of the Lessor, and the successors and assigns of the Lessor.” Exhibits 21, 22 and 23.
     
      
      . In the May 21 letters Paramount and Dow agreed
      that payment defaults under the Lease remain outstanding notwithstanding any payments received by [Dow] from [Paramount]. In particular, [Paramount] propos[es] to suspend payments under the guaranty until the Lease is assumed or rejected. In consideration for [Dow’s] agreement to such a deferral, [Paramount] would agree to advance sufficient funds to [Dow] to fully compensate [Dow] for payments that [Dow] would have received under the guaranty.
      In the event that Lessee assumes the Lease and cures all payment defaults [Dow] will repay to [Paramount] (without interest) all amounts which [Paramount] has advanced to [Dow] under this letter agreement. In the event that the Lease is rejected by the Lessee, [Dow] may apply the amounts advanced hereunder to the obligations under [Paramount’s] guaranty of the Lease payments. In the interim [Dow] will have the use of such funds.
      Williamson Affidavit, Exhs. 28, 29 & 30, at 2.
     
      
      . Pandora was at that time known as HDZ Corporation.
     
      
      . As the Supreme Court long ago stated,
      Among the oldest ... [equitable doctrines] is the rule of subrogation whereby one who has been compelled to pay a debt that ought to have been paid by another is entitled to exercise all remedies which the creditor possessed against that other.
      
        American Surety Co. v. Bethlehem National Bank, 314 U.S. 314, 317, 62 S.Ct. 226, 228, 86 L.Ed. 241 (1941).
     
      
      . Section 507(d) of the Code provides that
      "An entity that is subrogated to the rights of a holder of a claim of a kind specified in this section (a)(3), (a)(4), (a)(5), or (a)(6) of this section is not subrogated to the right of the holder of such claim to priority under such subsection.” 11 U.S.C. § 507(d).
     