Commit d29ed174 authored by Steven Jones's avatar Steven Jones

Issue #1510572 by Steven Jones: Fixed Why do we use mktime() instead of time() ?.

parent c4eed04e
......@@ -115,7 +115,7 @@ class Provision_Service_example_basic extends Provision_Service_example {
* You could also choose to only conditionally pass values based on
* the parameters.
*/
$data['example_current_time'] = date(DATE_COOKIE, mktime());
$data['example_current_time'] = date(DATE_COOKIE, time());
return $data;
}
......
......@@ -36,12 +36,12 @@ function drush_provision_drupal_provision_backup_validate($backup_file = NULL) {
}
if (!$backup_file) {
$suggested = d()->platform->server->backup_path . '/' . d()->uri . '-' . date("Ymd.His", mktime()) . '.tar.gz';
$suggested = d()->platform->server->backup_path . '/' . d()->uri . '-' . date("Ymd.His", time()) . '.tar.gz';
// Use format of mysite.com-2008-01-02, if already existing, add number.
while (is_file($suggested)) {
$count++;
$suggested = d()->platform->server->backup_path . '/' . d()->uri . '-' . date('Ymd.His', mktime()) . '_' . $count . '.tar.gz';
$suggested = d()->platform->server->backup_path . '/' . d()->uri . '-' . date('Ymd.His', time()) . '_' . $count . '.tar.gz';
}
drush_set_option('backup_file', $suggested);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment