Fixed last return id for new provider and location insert

Fixed last return id for new provider and location insert
This commit is contained in:
cp6 2021-01-24 13:33:45 +11:00
parent fdc31bc2fd
commit 8a6b1ea54e

View File

@ -1819,7 +1819,7 @@ class idlers extends helperFunctions
} else {//NO
$insert = $this->dbConnect()->prepare('INSERT INTO `locations` (`name`) VALUES (?);');
$insert->execute([$provider]);
return $db->lastInsertId();
return $this->dbConnect()->lastInsertId();
}
}
@ -1833,7 +1833,7 @@ class idlers extends helperFunctions
} else {//NO
$insert = $this->dbConnect()->prepare('INSERT INTO `providers` (`name`) VALUES (?);');
$insert->execute([$provider]);
return $db->lastInsertId();
return $this->dbConnect()->lastInsertId();
}
}