BANGOR, Maine (AP) — Prosecutors have dropped a murder charge against a Maine man as part of a plea deal.

In exchange, 27-year-old Justin Ptaszynski of Bangor changed his plea Friday from not guilty to guilty for hindering apprehension or prosecution in connection with the death of Holly Boutilier.

Under the agreement, Ptaszynski would serve at least six years in prison. Court documents say Ptaszynski was present when Boutilier was stabbed to death in a shack under the I-395 Bridge in Bangor last August, but did not kill her. Prosecutors say he concealed evidence.

Thirty-four-year-old Colin Koehler of Bangor is awaiting trial on murder charges.