changed published to type bool for post model