I think Alexey went ahead too quickly… The current lensfun version in MSYS2 is 0.39.5, which is an alpha version of lensfun, probably should have waited a bit.
Anyhow, you can roll back to an earlier version of a package anytime with:
pacman -U /var/cache/pacman/pkg/packagename-old_version.pkg.tar.xz
And if you want also can set in /etc/pacman.conf to ignore the updates for a specific package
I guess that solves your immediate problem, but on the other side we should also think about how to replace the (to-be) deprecated lensfun calls.