HARRISBURG, Pa. (AP) — U.S. Rep. Fred Keller of Pennsylvania changed his mind Monday and said he will not run for reelection if he must face a primary election against another Republican incumbent.

Pennsylvania’s highest court selected new boundaries for congressional districts last week, and Keller and U.S. Rep. Glenn Thompson — who represent vast swaths of northern Pennsylvania where the population is shrinking or stagnant — found their homes drawn into the same district, as the state adjusts to losing a seat.

Get daily news, weather, breaking news, and alerts straight to your inbox! Sign up for the abc27 newsletters here

In a statement, Keller said, “I am not going to run against another member of Pennsylvania’s Republican Congressional Delegation.”

Instead of challenging Thompson, Keller had initially said he would run in the new 9th District next door, where Republican Rep. Dan Meuser lives.

Keller, 56, was elected in a special election in 2019 and is the newest member of Pennsylvania’s delegation.

Keller blamed the “liberal Pennsylvania Supreme Court,” accusing it of overstepping its authority and selecting a map that favors Democrats. However, the boundaries of his current district and Thompson’s current district needed to grow substantially because of the shrinking population there.

The Democratic-majority state Supreme Court in a 4-3 decision picked a 17-district map that had been proposed by a group of Democratic Party-aligned voters. The court picked the map after Gov. Tom Wolf, a Democrat, and the Republican-controlled Legislature deadlocked.

The map is unlikely to create a big shift in the makeup of the congressional delegation.