here is a patch (with small regress test)
pgsql-hackers by date:
Соглашаюсь с условиями обработки персональных данных