Don't update the page id with a bad value.

fix #648