How did I fix «Synchronizing state of proftpd.service with SysV service script with /lib/systemd/systemd-sysv-install» / «Could not execute systemctl: at /usr/bin/deb-systemd-invoke line 142» after upgrading Ubuntu from 20 to 22?

Synchronizing state of proftpd.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable proftpd
Could not execute systemctl:  at /usr/bin/deb-systemd-invoke line 142.

2024-08-31--06-26-47

apt remove proftpd-mod-crypto
apt remove proftpd-mod-wrap
apt remove proftpd-core
apt autoremove