When Derek Rotondo, a seven-year investigator with JPMorgan Chase, asked to take the company’s 16-week paid parental leave, he was told that “only mothers are automatically considered to be primary caregivers.”

Rotondo said he was “shocked” that, as a father, he was not considered a “primary caregiver” unless he could show that his spouse was incapacitated or had returned to work. He was offered only two weeks of paid parental leave.

But now, thanks to a gender-discrimination complaint he filed in June 2017 with the Equal Employment Opportunity Commission, that policy has changed.

The complaint resulted in a “first-of-its kind” class-action settlement on Thursday, in which the bank agreed to pay $5 million to about 5,000 fathers who allege they were denied the opportunity to take appropriate paid parental leave as primary caregivers between 2011 and 2017. The American Civil Liberties Union, workers’ rights law firm Outten & Golden LLP, and JPMorgan Chase announced the tentative settlement.

“I love my children, and all I wanted was to spend time with them when they were born,” Rotondo said in a statement. “I’m proud that since I filed my charge, Chase has clarified its policy to ensure that both male and female employees who wish to be the primary parental caregiver have equal access to those benefits.”

To be clear, just days after Rotondo filed his EEOC complaint, Chase granted him the full 16 weeks of caregiver leave. The company also clarified its policy in Dec. 2017 to make sure that there was gender neutral access to paid parental leave.

In the federal settlement, which was filed Thursday in U.S. District Court in Ohio, JPMorgan Chase also agreed to maintain the current gender-neutral parental leave policy and to train those administering it on its gender-neutral application. The company’s associate general counsel, Reid Broda, on Thursday thanked Rotondo for “bringing this matter to our attention.”

Since Rotondo’s case, the company also reportedly increased the parental leave available to non-primary caregivers to six weeks.

“Paid parental leave is crucial for all parents, and it should be up to families, not employers, what their caregiving arrangements will look like,” said Freda Levenson, legal director for the ACLU of Ohio.

“In order for women to compete on an even playing field at work, we need to ensure that men can play an active role at home,” she added.