Commit cbdcc5f1 authored by Sebastian Kummer's avatar Sebastian Kummer

ZP-1195 Call Request::GetUser() only once.

Released under the Affero GNU General Public License (AGPL) version 3.
parent 6fa1485a
......@@ -54,9 +54,10 @@ class WebserviceDevice {
* @return ASDevice object
*/
public function GetDeviceDetails($deviceId) {
$deviceId = preg_replace("/[^A-Za-z0-9]/", "", $deviceId);
ZLog::Write(LOGLEVEL_INFO, sprintf("WebserviceDevice::GetDeviceDetails('%s'): getting device details from state of user '%s'", $deviceId, Request::GetGETUser()));
$user = Request::GetGETUser();
$deviceId = preg_replace("/[^A-Za-z0-9]/", "", $deviceId);
ZLog::Write(LOGLEVEL_INFO, sprintf("WebserviceDevice::GetDeviceDetails('%s'): getting device details from state of user '%s'", $deviceId, $user));
ZPush::GetTopCollector()->AnnounceInformation(sprintf("Retrieved details of device '%s'", $deviceId), true);
return ZPushAdmin::GetDeviceDetails($deviceId, $user);
}
......
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