Merge pull request #5840 from totten/4.6-cron-lock-2
[civicrm-core.git] / CRM / Upgrade / Headless.php
index a56de4a8beef769162d0d7d6530b9999e798e10f..7e0cc130b4cc32d5e299b6675c0cb84af4ea003e 100644 (file)
@@ -3,7 +3,7 @@
  +--------------------------------------------------------------------+
  | CiviCRM version 4.6                                                |
  +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2014                                |
+ | Copyright CiviCRM LLC (c) 2004-2015                                |
  +--------------------------------------------------------------------+
  | This file is a part of CiviCRM.                                    |
  |                                                                    |
@@ -23,7 +23,7 @@
  | GNU Affero General Public License or the licensing of CiviCRM,     |
  | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
  +--------------------------------------------------------------------+
-*/
+ */
 
 /**
  * Perform an upgrade without using the web-frontend
@@ -35,7 +35,6 @@ class CRM_Upgrade_Headless {
    *
    * @param bool $enablePrint
    *
-   * @throws
    * @throws Exception
    * @return array, with keys:
    *   - message: string, HTML-ish blob
@@ -62,9 +61,9 @@ class CRM_Upgrade_Headless {
 
     $postUpgradeMessageFile = CRM_Utils_File::tempnam('civicrm-post-upgrade');
     $queueRunner = new CRM_Queue_Runner(array(
-        'title' => ts('CiviCRM Upgrade Tasks'),
-        'queue' => CRM_Upgrade_Form::buildQueue($currentVer, $latestVer, $postUpgradeMessageFile),
-      ));
+      'title' => ts('CiviCRM Upgrade Tasks'),
+      'queue' => CRM_Upgrade_Form::buildQueue($currentVer, $latestVer, $postUpgradeMessageFile),
+    ));
     $queueResult = $queueRunner->runAll();
     if ($queueResult !== TRUE) {
       $errorMessage = CRM_Core_Error::formatTextException($queueResult['exception']);
@@ -82,4 +81,5 @@ class CRM_Upgrade_Headless {
       'message' => file_get_contents($postUpgradeMessageFile),
     );
   }
+
 }