Fix #416: UPDATEs from Lua can't be properly restored
Merge remote-tracking branch 'origin/gh-416-update-one-based'