updating publish var