Issue #1623536 by Artem Dotsenko: Avoid errors when updating object via entity APIs.