fix #1196
This commit is contained in:
+1
-2
@@ -40,7 +40,6 @@ class Server
|
||||
$this->setCapabilities();
|
||||
$this->callbacks = $callbacks;
|
||||
$this->setCallbacks();
|
||||
$this->serve();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -298,7 +297,7 @@ class Server
|
||||
/**
|
||||
* 服务入口
|
||||
*/
|
||||
private function serve()
|
||||
public function serve()
|
||||
{
|
||||
$message = new Message(file_get_contents('php://input') ?: '');
|
||||
|
||||
|
||||
@@ -1532,7 +1532,7 @@ class XmlRpc extends Contents implements ActionInterface, Hook
|
||||
[
|
||||
'isAdmin' => $this->user->pass('administrator', true),
|
||||
'url' => $this->options->siteUrl,
|
||||
'blogid' => '1',
|
||||
'blogid' => 1,
|
||||
'blogName' => $this->options->title,
|
||||
'xmlrpc' => $this->options->xmlRpcUrl
|
||||
]
|
||||
@@ -1897,7 +1897,9 @@ EOF;
|
||||
}
|
||||
|
||||
/** 直接把初始化放到这里 */
|
||||
new Server($api);
|
||||
$server = new Server($api);
|
||||
$server->setHook($this);
|
||||
$server->serve();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user