Fixed post count bug and duplicate posts