summaryrefslogtreecommitdiffstats
path: root/modules-available/remoteaccess/hooks/client-update.inc.php
blob: ecf5d91cb2806d45ce4b625923feb12d9d10de14 (plain) (blame)
1
2
3
4
5
6
7
8
9
<?php

if ($type === '~poweron') {
	Database::exec("UPDATE remoteaccess_machine SET password = NULL WHERE machineuuid = :uuid",
		['uuid' => $uuid]);
} elseif ($type === '~poweroff') {
	Database::exec("UPDATE remoteaccess_machine SET woltime = 0 WHERE machineuuid = :uuid",
		['uuid' => $uuid]);
}