add published checkbox logic