Remove unavailable method call
This commit is contained in:
parent
912577617e
commit
123e3fadfd
|
@ -74,10 +74,10 @@ class MysqlArray implements DbArray
|
||||||
foreach ((array) $value as $key => $item) {
|
foreach ((array) $value as $key => $item) {
|
||||||
$counter++;
|
$counter++;
|
||||||
if ($counter % 100 === 0) {
|
if ($counter % 100 === 0) {
|
||||||
yield $instance->offsetSetAsync($key, $item);
|
yield from $instance->offsetSet($key, $item);
|
||||||
Logger::log("Converting database. $counter/$total", Logger::WARNING);
|
Logger::log("Converting database. $counter/$total", Logger::WARNING);
|
||||||
} else {
|
} else {
|
||||||
$instance->offsetSetAsync($key, $item);
|
$instance->offsetSet($key, $item);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -136,18 +136,18 @@ class MysqlArray implements DbArray
|
||||||
* </p>
|
* </p>
|
||||||
* @param $value
|
* @param $value
|
||||||
*
|
*
|
||||||
* @return Promise
|
* @return void
|
||||||
* @throws \Throwable
|
* @throws \Throwable
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public function offsetSet($index, $value): void
|
public function offsetSet($index, $value)
|
||||||
{
|
{
|
||||||
if ($this->getCache($index) === $value) {
|
if ($this->getCache($index) === $value) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$this->setCache($index, $value);
|
$this->setCache($index, $value);
|
||||||
|
|
||||||
$this->request("
|
yield $this->request("
|
||||||
INSERT INTO `{$this->table}`
|
INSERT INTO `{$this->table}`
|
||||||
SET `key` = :index, `value` = :value
|
SET `key` = :index, `value` = :value
|
||||||
ON DUPLICATE KEY UPDATE `value` = :value
|
ON DUPLICATE KEY UPDATE `value` = :value
|
||||||
|
|
Loading…
Reference in New Issue
Block a user