Update to 2.2.2

This PR pulls in @otrimegistro s fork with 2.2.2 compatibility.