diff --git a/op/op.SetRevisors.php b/op/op.SetRevisors.php index 672cd6677..3716b0183 100644 --- a/op/op.SetRevisors.php +++ b/op/op.SetRevisors.php @@ -55,10 +55,12 @@ if (!is_object($content)) { UI::exitError(getMLText("document_title", array("documentname" => $document->getName())),getMLText("invalid_version")); } -if (isset($_POST["startdate"])) { +$ts = null; +if (!empty($_POST["startdate"])) { $ts = makeTsFromDate($_POST["startdate"]); -} else { - $ts = time(); +} +if(!$ts) { + UI::exitError(getMLText("document_title", array("documentname" => $document->getName())),getMLText("invalid_revision_date")); } $startdate = date('Y-m-d', $ts);