OPINION BY
Senior Judge ROCHELLE S. FRIEDMAN.Four Score Property, LLC (Four Score) appeals from the December 12, 2013, order of the Court of Common Pleas of Adams County (trial court) that denied Four Score’s appeal from the decision of the Code Enforcement Appeals Board (Board) of the Borough of Gettysburg (Borough), which upheld Four Score’s violation of section 705.1 of the Borough’s Property Maintenance Code Ordinance (PMC). We affirm.
Four Score is the owner of real property located at 48 Chambersburg Street (Property) in the Borough. The Property is located on the south side of Chambersburg Street and abuts Zerfing Alley to the south. The Property is improved with a building that is approximately 30 feet wide and 150 feet deep. The lot on which the building is located is approximately 30 feet wide and 180 feet deep. The oldest part of the building was built before 1864. There have been additions to the building, the newest of which was added in the 1950s. Four Score purchased the Property in November 2005.
The building contains one retail space fronting on Chambersburg Street; five single rooms, four of which are rented out and one of which is used for storage; and 15 apartments.1 All 15 apartments were licensed for occupancy by the Borough when Four Score purchased the Property and have been continuously licensed.
Two of the apartments, numbers 21 and 22, are located in the basement of the building and are the subject of this appeal. The two apartments are similar in layout, each having only one door that leads from the living area into an interior hallway that abuts the west side of the building. Normal ingress and egress from the apartments is south through the interior hallway, through a laundry area, and up stairs to the rear entrance of the building. The rear entrance opens into a parking area that abuts Zerfing Alley. Alternate egress can be obtained by proceeding north along the interior hallway, through an unlocked door marked with an emergency exit sign, and proceeding through a hallway to a flight of stairs marked with another emergency exit sign to the first floor front entrance, which exits onto Chambersburg Street. The door at the top of the stairway is locked from the inside. Therefore, this route does not provide a secondary *1131means of ingress to the basement apartments.
Apartments 21 and 22 each have one bedroom that abuts the interior hallway on the west side of the building. Entrance to the bedrooms is through the living area of each apartment'. The kitchen and bathroom in each apartment abut the exterior wall along the east side of the building. Water, sewer, and natural gas lines run inside the exterior wall. Each apartment has one window, approximately 30 inches wide by 16 inches high, in the kitchen on the east side of the building.
On November 19, 2012, William Mellors, an agent of the Commonwealth Code Inspection Service, Inc., the duly appointed code enforcement officer for the Borough, inspected the Property. Mellors cited Four Score for violating section 705.1 of the PMC,2 for not having at least one operable emergency and rescue opening with a minimum net clear opening of 5.7 square feet directly onto a public street, public alley, yard, or court from a basement sleeping area.3
On November 28, 2012, Four Score appealed the citation to the Board. On January 16, 2013, the Board conducted a hearing at which James D. Walsh testified on behalf of Four Score. Walsh stated that due to the existing water, sewer, and natural gas lines, it was not feasible to reverse the orientation of the apartments so that each bedroom would be along the east side of the building where the only window is located. Further, even if Four Score could reverse the orientation of the apartments, the existing window is too small to comply with the PMC. If the windows were made larger, they would extend below grade level, and a window well would not be an option because the sides of the building abut the Property’s lot lines. Four Score proposed the installation of new doors from each bedroom that would open directly into the interior hallway, eliminating the tenant’s need to go through the living area to exit the apartment, panic hardware, and other upgrades to improve egress and safety.
On February 12, 2013, the Board upheld Four Score’s violation of section 705.1 of the PMC. On March 14, 2013, Four Score appealed to the trial court. The trial court, without holding a hearing or taking additional evidence, denied Four Score’s appeal on December 12, 2013. On January 13, 2014, Four Score appealed to this court.4
Initially, Four Score contends that section 705.1 of the PMC violates section *1132104 of the Pennsylvania Construction Code Act (Act), Act of November 10, 1999, P.L. 491, as amended, 35 P.S. § 7210.104, which prohibits retroactive application of amendments to a construction code. We disagree.
Specifically, Four Score argues that the Borough is attempting to circumvent the Act by labeling a retroactive local construction code as a property maintenance code. Four Score maintains that the Borough is using section 705.1 of the PMC to require Four Score to make structural changes to its building or lose the use of its two basement apartments.
Section 104(a) of the Act states that the Act applies “to the construction, alteration, repair and occupancy of all buildings in this Commonwealth.” 35 P.S. § 7210.104(a). Section 104(b)(1) of the Act expressly exempts “new buildings or renovations to existing buildings for which an application for a building permit has been made to the municipality prior to the effective date of the regulations promulgated under this act.” 35 P.S. § 7210.104(b)(1). The regulations promulgated under the Act, Pennsylvania’s Uniform Construction Code, provide that “[t]he legal occupancy of a structure existing on April 9, 2004, may continue without change except where the Uniform Construction Code provides otherwise.” 34 Pa.Code § 403.1(d)(3).'
Section 3204-A of The Borough Code5 states that “[n]otwithstanding the primacy of the Uniform Construction Code, a borough may enact a property maintenance ordinance.”6 Section 1202(24) of The Borough Code authorizes the Borough “[t]o enact and enforce ordinances relating to buildings and housing, their construction, alteration, extension, repair and maintenance and all facilities and services in or about such building or housing.” 53 P.S. § 46202(24).7 The PMC was enacted pursuant to The Borough Code.
Section 705.1 of the PMC states that basement sleeping rooms shall have at least one operable emergency and rescue opening that opens directly onto a public street, alley, yard, or court.
The PMC protects the health and safety of the residents of Four Score’s building by requiring an emergency and rescue opening in basement sleeping rooms. Regulation by means of egress and fire safety are included in the International Property Maintenance Code and the enabling legislation at 53 P.S. § 48204,8 which specifically authorizes a borough to incorporate all or part of any nationally recognized property maintenance code.
We agree with Four Score that the regulations under the Act provide that legal occupancy existing on April 9, 2004, is permitted to continue “except where the Uniform Construction Code provides otherwise.” 34 Pa.Code § 403.1(d)(3). However, specific exceptions to this rule include “inadequate means of egress, ... fire hazard, [or] other dangers to human life or the public welfare.” 34 Pa.Code § 403.84(a).
In Wood v. City of Pittsburgh, 74 Pa.Cmwlth. 450, 460 A.2d 390, 392 (1983), this court upheld the retroactive application of a municipal ordinance where fire and safe*1133ty issues were implicated. In Wood, the building owner objected to the application of a minimum egress provision in a building code adopted after construction of his building. Id. at 391. This court determined that the code could be applied retroactively and upheld the trial court’s injunction prohibiting the owner from occupying or using the building until fire escapes were installed. Id. at 392.
■Here, the regulation objected to by Four Score addresses fire and safety issues by requiring adequate egress. As such, the PMC is properly enforced by the Borough and does not contravene the Act.
Next, Four Score contends that the Board erred in denying it a de minimis waiver to provide alternate exit routes for safe egress from the basement sleeping rooms. Four Score maintains that a waiver is necessary because it is physically impossible for Four Score to comply with the provisions of section 705.1 of the PMC.
Granting or denying a de minim-is waiver is within the Board’s discretion, and the applicant bears the burden of proof. Swemley v. Zoning Hearing Board of Windsor Township, 698 A.2d 160, 163 (Pa.Cmwlth.1997). An applicant is entitled to a de minimis waiver if: (1) it is seeking only a minor deviation from an ordinance, and (2) rigid compliance with the ordinance is not necessary to protect the public. Constantino v. Zoning Hearing Board of the Borough of Forest Hills, 152 Pa.Cmwlth. 258, 618 A.2d 1193, 1196 (1992).
To meet the first prong of the test, Four Score proposed to install emergency exit doors that would open from each bedroom into a common hallway. Four Score contends that this is a minor deviation from the PMC, as it provides an exit from the bedroom, just not an exit directly to the outside of the building. As to the second prong of the test, Four Score argues that there is nothing inherently dangerous about sleeping rooms that would require outside exits in order to protect the public.
Here, the Board found that Four Score did not satisfy either prong. The Board determined that the deviation from the PMC was not minimal because Four Score’s proposal did not provide a direct means of egress from the basement bedrooms to a street, alley, or yard. With regard to the second prong, the Board determined that an emergency exit from a basement apartment bedroom was necessary to protect the public. The Board did not err, as it was within the Board’s discretion to deny the de. minimis waiver.
Finally, Four Score contends that the Board’s decision denies Four Score use of its two licensed basement apartments and, therefore, constitutes a taking of private property without just compensation, which is prohibited by both the Fifth Amendment of the United States Constitution and by Article I, Section 10 of the Pennsylvania Constitution.
A property owner bears the burden of proving that a governmental regulation substantially deprives the owner of the use of its property. Michael T. Tobin, Jr., Contractors v. Centre Township, 954 A.2d 741, 746 (Pa.Cmwlth.2008). A regulation that deprives an owner of the most profitable use of its property is not necessarily a taking compensable under the Fifth Amendment. Machipongo Land and Coal Company, Inc. v. Department of Environmental Protection, 569 Pa. 3, 799 A.2d 751, 764 (2002).
Here, the Borough’s actions did not amount to an unconstitutional taking of Four Score’s Property. Four Score failed to present any evidence to the Board that the PMC prevents it from using the remaining 13 apartments or that it is unable to use apartments 21 and 22 for any other *1134lawful purpose. Therefore, because Four Score failed to show that the regulation substantially deprives it of the use of its property, the Board did not err.
Accordingly, we affirm.
ORDER
AND NOW, this 16th day of July, 2015, we hereby affirm the December 12, 2013, order of the Court of Common Pleas of Adams County.
. We note that both the Board and the trial court state that there are 17 apartments. However, the record reflects that there are 15 apartments. (N.T., 1/16/13, at 10.)
. Mellors cited Four Score for five violations of the PMC, only one of which is the subject of this appeal.
. Section 705.1 of the PMC provides:
Emergency escape and rescue required. Basement sleeping rooms shall have at least one operable emergency and rescue opening. Such opening shall open directly onto a public street, public alley, yard or court. Where basements contain more than one sleeping room, emergency escape and rescue openings shall be required in each sleeping room. Emergency escape and rescue openings shall have a sill height of not more than 44 inches (1,118 mm) above the floor. The net clear opening dimensions required by this section shall be obtained by the normal operation of the emergency escape and rescue opening from the inside. Emergency escape and rescue openings with a finished sill height below the adjacent ground ■ elevation shall be provided with a window well in accordance with Section 705.2. Such emergency escape and rescue openings shall open directly onto a public way or to a yard or court that opens onto a public way.
.Where, as here, the trial court did not take additional evidence, our review is limited to whether the Board committed an error of law or abused its discretion. Swemley v. Zoning Hearing Board of Windsor Township, 698 A.2d 160, 162 (Pa.Cmwlth.1997).
. Act of February 1, 1966, P.L. (1965) 1656, as amended, 53 P.S. §§ 45101-48501.
. Section 3204-A of The Borough Code was added by the Act of May 17, 2012, P.L. 262, formerly, 53 P.S. § 48204-A, and was rewritten and consolidated at 8 Pa.C.S. § 32A04, effective June 17, 2014.
. Section 1202(24) of The Borough Code, 53 P.S. § 46202(24), was re-written and consolidated at 8 Pa.C.S. § 1202(15), effective June 17, 2014.
. See supra note 6.