X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/timetracker.git/blobdiff_plain/b43967e75a9a02e61a8ac2263f3b5432556d661f..c30bd94928988ff03ade10ca872968681456e12c:/WEB-INF/lib/ttRoleHelper.class.php diff --git a/WEB-INF/lib/ttRoleHelper.class.php b/WEB-INF/lib/ttRoleHelper.class.php index c14bc970..0686b1cd 100644 --- a/WEB-INF/lib/ttRoleHelper.class.php +++ b/WEB-INF/lib/ttRoleHelper.class.php @@ -173,10 +173,7 @@ class ttRoleHelper { if (is_a($affected, 'PEAR_Error')) return false; - $sql = "SELECT LAST_INSERT_ID() AS last_id"; - $res = $mdb2->query($sql); - $val = $res->fetchRow(); - $last_id = $val['last_id']; + $last_id = $mdb2->lastInsertID('tt_roles', 'id'); return $last_id; }