Skip to content

Commit

Permalink
Merge pull request #4 from teppokoivula/master
Browse files Browse the repository at this point in the history
Allow unpublishing a page with blank publish_from
  • Loading branch information
formmailer committed Mar 15, 2013
2 parents 9ca5e45 + 44cde03 commit c469691
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion SchedulePages.module
Expand Up @@ -157,7 +157,8 @@ class SchedulePages extends WireData implements Module, ConfigurableModule {
// Publish pages with a publish_until date > current date (and publish_until is set)
if ($p->publish_until > 0 && $p->publish_until <= $time) {
// We keep it unpublished, since publish until is set and valid
} else {
} else if ($p->publish_from) {
// If publish_from is defined, publish page
$p->removeStatus(Page::statusUnpublished);
$p->save();
}
Expand Down

0 comments on commit c469691

Please sign in to comment.