Gallic trappers does not work right #473

Thanks @Dayran
This commit is contained in:
Shadow
2018-01-15 08:34:39 +02:00
committed by GitHub
parent 500636a8a8
commit b2133ddbc0
+16 -4
View File
@@ -7673,9 +7673,21 @@ References: User ID/Message ID, Mode
return self::$prisonersCacheByID[$id];
}
function getPrisoners3($from) {
return $this->getPrisoners($from, 1);
}
function getPrisoners3($from, $use_cache = true) { //change all this function arrange Dayran prisoners
list($from) = $this->escape_input((int) $from);
// first of all, check if we should be using cache and whether the field
// required is already cached
if ($use_cache && ($cachedValue = self::returnCachedContent(self::$prisonersCacheByVillageAndFromIDs, $from)) && !is_null($cachedValue)) {
return $cachedValue;
}
$q = "SELECT * FROM " . TB_PREFIX . "prisoners where " . TB_PREFIX . "prisoners.from = $from";
$result = mysqli_query($this->dblink,$q);
self::$prisonersCacheByVillageAndFromIDs[$wid.$from] = $this->mysqli_fetch_all($result);
return self::$prisonersCacheByVillageAndFromIDs[$from];
}//hasta aki
function deletePrisoners($id) {
if (!is_array($id)) {
@@ -7934,4 +7946,4 @@ if (!in_array($req_file, ['tutorial.php', 'anleitung.php'])) {
$database->sendPendingMessages();
});
}
?>
?>