Add back some code lost in last merge.