Unverified Commit 6eec8b60 authored by Seamus Lee's avatar Seamus Lee Committed by GitHub

Merge pull request #14186 from MegaphoneJon/wordpress-26

Fix REST on WordPress
parents 96335902 db81692d
......@@ -472,9 +472,6 @@ class CRM_Utils_System_WordPress extends CRM_Utils_System_Base {
$name = CRM_Utils_Array::value('name', $params);
$pass = CRM_Utils_Array::value('pass', $params);
if (isset($params['uid'])) {
throw new \RuntimeException("Not implemented WordPress::loadBootStrap([uid=>\$num]))");
}
if (!defined('WP_USE_THEMES')) {
define('WP_USE_THEMES', FALSE);
......@@ -500,7 +497,7 @@ class CRM_Utils_System_WordPress extends CRM_Utils_System_Base {
CRM_Core_Config::singleton()->userSystem->setMySQLTimeZone();
}
require_once $cmsRootPath . DIRECTORY_SEPARATOR . 'wp-includes/pluggable.php';
$uid = CRM_Utils_Array::value('uid', $name);
$uid = CRM_Utils_Array::value('uid', $params);
if (!$uid) {
$name = $name ? $name : trim(CRM_Utils_Array::value('name', $_REQUEST));
$pass = $pass ? $pass : trim(CRM_Utils_Array::value('pass', $_REQUEST));
......
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