fix return value of pubUpdate() (fix #334)

@tfoote @wjwwood Please review.