Reliever Cody Stashak, who pitched in parts of the past four seasons for the Twins, elected to become a free agent Friday.

The 28-year-old righthander, who had shoulder surgery after pitching in only 16 innings in 2022, had been outrighted by the Twins. He cleared waivers and decided to cast his lot with another organization.

Stashak pitched in 55 games over four seasons, going 4-1 with a 4.13 ERA and 1.194 WHIP. In 72 innings, he struck out 83.

In 11 games last season before his shoulder injury, he was 3-0 with a 3.86 ERA.

The mid-June surgery will likely prevent Stashak from pitching until midseason 2023. Los Angeles Dodgers surgeon Neal ElAttrache did the procedure to reattach Stashak's biceps to his pitching shoulder.

Stashak was a 13th round pick in 2015 out of St. John's (N.Y.).