fixed a recent posts bug

fixed a bug where all post would have been pulled regardless if they
were published or not