
736 A.2d 52 (1999)
GREENE COUNTY and Greene County Children and Youth Services
v.
DISTRICT 2, UNITED MINE WORKERS OF AMERICA and Local Union 9999, United Mine Workers of America, Appellants.
Commonwealth Court of Pennsylvania.
Argued June 17, 1999.
Decided July 29, 1999.
*54 Michael J. Healey, Pittsburgh, for appellants.
Ronald J. Zers, Pittsburgh, for appellees.
Before PELLEGRINI, J., FLAHERTY, J., and NARICK, Senior Judge.
*53 NARICK, Senior Judge.
The issue presented is whether it was "manifestly unreasonable" for a labor arbitrator to conclude that Greene County Children and Youth Services (CYS) bargained away its right to discharge an employee whose poor record keeping jeopardized the safety of the children whom CYS is charged to protect. Because it was, the decision of the Court of Common Pleas of Greene County (trial court), which vacated the decision of the arbitrator, is affirmed.
The relevant facts are as follows. On December 8, 1997, Christopher McKenzie (Grievant), a caseworker for CYS, was discharged due to poor record keeping. The keeping of well organized, up-to-date records is a vital part of a CYS caseworker's job because such records aid in keeping track of and protecting abused and neglected children in the county. Detailed record keeping requirements, in fact, are contained in the Pennsylvania Code.[1]
On December 12, 1997, Grievant filed a grievance with his bargaining representative, the United Mine Workers of America, Local 9999, which entered into a collective bargaining agreement (CBA) with CYS on April 24, 1997. The dispute proceeded to arbitration, and an arbitrator found that, despite the fact that Grievant was guilty of poor record keeping as charged by CYS, there were mitigating factors which called for a penalty less severe than discharge. The arbitrator thus modified Grievant's penalty from a discharge to a suspension.
CYS appealed the arbitrator's decision to the trial court, and both parties filed motions for summary judgment. The trial court granted CYS' motion and vacated the arbitrator's decision, thus reinstating CYS' penalty of discharge. The trial court reasoned that record keeping is such an essential element of a CYS caseworker's job that the arbitrator should have upheld Grievant's discharge upon finding that Grievant was in fact guilty of poor record keeping, and that it was unreasonable for the arbitrator to consider mitigating factors and overturn CYS' discharge of Grievant. Said the trial court:
Plainly, record keeping is extremely important to the operation of a county Children and Youth Services Agency. All government agencies create voluminous records, but few receive such detailed instructions concerning the compilation of those records. The reason is obvious: a child's situation can be so fluid and dynamic that his records must be current, extensive and available to various interested parties. The changes in a child's life and environment over the course of a year in even a stable and loving family can be dramatic; the changes over the same period for an abused or neglected child, with residences in various foster homes, court appearances, testing, counseling, and other therapeutic interventions, can be profound. Considering that an emergency can arise at any time when any caseworker could be out of the office, or on vacation, or on sick leave, the most important resource available to the caseworker's supervisor or a replacement caseworker is the case file. Should a caseworker resign, his or her caseload might remain a mystery for months to the replacement caseworker in the absence *55 of a complete, well-documented family file.
On appeal to this Court, Grievant argues that the trial court erred in vacating the arbitrator's decision because the arbitrator's modification of Grievant's discipline from a discharge to a suspension drew its "essence" from the CBA. We disagree.
When reviewing the decisions of arbitrators, the courts of this Commonwealth must uphold the arbitrators' decisions as long as those decisions are reasonable and based on the CBA. Crawford County v. AFSCME District Council, 85 Local Union No. 2643, 693 A.2d 1385 (Pa. Cmwlth.), appeal denied, 550 Pa. 693, 704 A.2d 1383 (1997). Under this test, which has become known as the "essence test," courts are confined to determining whether the arbitrator's decision could rationally be derived from the CBA, viewed in light of its language, context, and any other indicia of the parties' intentions. Pennsylvania Liquor Control Board v. Independent State Stores Union, 520 Pa. 266, 553 A.2d 948 (1989).
Where the CBA does not explicitly define "just cause," it is within the province of the arbitrator to give meaning to that phrase. School District of Springfield Township v. Springfield Township Educational Support Personnel Association, 711 A.2d 602 (Pa.Cmwlth.1998). Furthermore, if "just cause" is not defined in the CBA and the CBA does not explicitly prohibit the arbitrator from modifying the discipline imposed by the employer, the arbitrator may determine that just cause does not exist for the discipline that was imposed and may modify the discipline accordingly. Upper St. Clair School District v. Upper St. Clair Educational Support Personnel Association, 168 Pa. Cmwlth. 1, 649 A.2d 470 (1994). Because the CBA in this case does not define just cause, nor does it explicitly prohibit the arbitrator from modifying the discipline imposed by CYS, Grievant argues that the arbitrator acted within his authority in modifying the discipline from a discharge to a suspension.
However, in limited circumstances, an arbitrator is not free to modify a penalty, even where the CBA is silent on the meaning of "just cause" and contains no prohibition on modifying a penalty. In such cases, the arbitrator must uphold the discipline imposed by the employer if the arbitrator finds as a fact that the grievant did commit the offenses of which he is charged. The first such circumstance is where there is specific language in the CBA delineating the exact discipline that must be imposed for a given offense. In such cases, once the arbitrator determines that the grievant did in fact engage in the conduct for which he or she was disciplined, the arbitrator is without authority to modify the discipline and must either uphold the discipline in its entirety or find that there was no just cause for any discipline. Riverview School District v. Riverview Education Association, 162 Pa. Cmwlth. 644, 639 A.2d 974 (1994), appeal denied, 540 Pa. 588, 655 A.2d 518 (1995). For example, if the CBA mandates that "Offense A results in Discipline B," the arbitrator must impose "Discipline B" upon finding that that the grievant committed "Offense A." In the present case, there is no such language in the CBA, and this restriction on the arbitrator's authority thus does not apply.
A second scenario in which an arbitrator is not free to modify the discipline imposed by the employer, and which does apply to this case, is where it would be "manifestly unreasonable" to conclude that the employer bargained away its right to discharge an employee for certain particularly egregious offenses, despite the silence on the issue in the CBA. Independent State Stores Union; Philadelphia Housing Authority v. Union of Security Officers # 1, 500 Pa. 213, 455 A.2d 625 (1983); Crawford County. A penalty modification by an arbitrator that is "manifestly unreasonable" is not considered to have drawn its essence from the CBA and thus *56 must be rejected because the arbitrator has exceeded his or her authority and gone beyond the four corners of the CBA. Crawford County.
In Crawford County, a prison warden discharged a corrections officer for failing to conduct strip searches of inmates returning from work release, ordering subordinate guards not to conduct these searches, and accepting gratuities from inmates. The union of which the sergeant was a member grieved the discharge, and an arbitrator modified the discipline from a discharge to a suspension. On appeal, the trial court sustained the arbitrator's decision. This Court, however, reversed and held that it was manifestly unreasonable to conclude that the prison bargained away its right to discharge any employee who undermined the prison's policy of searching inmates returning from work release for weapons or other contraband. Because the actions of the grievant jeopardized the safety of the very people the prison was charged with protecting, it would be manifestly unreasonable to conclude, although not explicitly stated in the CBA, that the prison bargained away its right to discharge a guard who committed such an offense. Said the court:
Finally, [grievant's] conduct constituted just cause for dismissal because it falls within the narrow definition of just cause that is implied in every public employer bargaining agreement. The Prison Board of Crawford County is statutorily charged with the duty and responsibility of managing the prison and providing for the well-being of inmates. When [grievant] failed to conduct strip searches and ordered other guards not to conduct strip searches as required by the prison work rules, he risked the health, safety, and welfare of all the other inmates whom the prison board had a statutory duty to protect, as well as his fellow employees. Inmates returning from work-release could have been smuggling weapons, or contraband into the prison. Given the propensities of prison inmates, prisoners and guards could have been greatly injured by such weapons.... The County did not bargain away its inherent managerial power to discharge employees who pose a threat to the very safety of the inmates for which the prison is exclusively responsible, thereby compromising the integrity of its operations. Under the terms of the Agreement and the facts of the instant case, the arbitrator was required to find that there was just cause for the discharge and his failure to do so was manifestly unreasonable.
As in Crawford, the actions of Grievant in the present case, although apparently negligent rather than intentional in nature, placed the well being of the very people whom CYS is charged with protecting in jeopardy  the abused and neglected children under CYS' supervision. As such, he compromised the integrity of CYS' operations. Under such circumstances, we cannot conclude that CYS bargained away its right to discharge a caseworker who committed the infractions which Grievant was found to have committed, and the arbitrator's decision to modify Grievant's discipline from a discharge to a suspension was thus manifestly unreasonable and did not draw its essence from the CBA.
Accordingly, the order of the trial court is affirmed.

ORDER
AND NOW, this 29th day of July, 1999, the order of the Court of Common Pleas of Greene County in the above-captioned matter is hereby affirmed.
Judge PELLEGRINI concurs in the result only.
NOTES
[1]  55 Pa.Code § 3130.43, for example, provides detailed instructions on information that must be contained in a family case record.
