From 6eca1321a35ba0b11b417cf1f58442a4e70e568d Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Tue, 21 Nov 2017 14:46:38 +0100 Subject: [statistics] Also adapt MAC-UUID fixing code to mltk changes Refs #3227 --- modules-available/statistics/api.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules-available/statistics/api.inc.php') diff --git a/modules-available/statistics/api.inc.php b/modules-available/statistics/api.inc.php index 566b1d69..c395220a 100644 --- a/modules-available/statistics/api.inc.php +++ b/modules-available/statistics/api.inc.php @@ -16,7 +16,7 @@ if ($type{0} === '~') { $uuid = Request::post('uuid', '', 'string'); if (strlen($uuid) !== 36) die("Invalid UUID.\n"); $macaddr = Request::post('macaddr', '', 'string'); - if (!empty($macaddr) && substr($uuid, 0, 16) === '000000000000000-') { + if (!empty($macaddr) && substr($uuid, 0, 16) === '000000000000001-') { // Override uuid if the mac is known and unique $res = Database::simpleQuery('SELECT machineuuid FROM machine WHERE macaddr = :macaddr AND machineuuid <> :uuid', compact('macaddr', 'uuid')); $override = false; -- cgit v1.2.3-55-g7522