Adding check for post visibility being 0 or more to fix #819.