fix(api): do not go online on every call

This commit is contained in:
mrilyew 2024-11-19 16:39:05 +03:00
parent 4046c992f9
commit b9687b1fb2
2 changed files with 2 additions and 1 deletions

View file

@ -256,7 +256,7 @@ abstract class OpenVKPresenter extends SimplePresenter
$userValidated = 1;
$cacheTime = 0; # Force no cache
if($this->user->identity->onlineStatus() == 0 && !($this->user->identity->isDeleted() || $this->user->identity->isBanned())) {
if(!property_exists($this, 'silent') && $this->user->identity->onlineStatus() == 0 && !($this->user->identity->isDeleted() || $this->user->identity->isBanned())) {
$this->user->identity->setOnline(time());
$this->user->identity->setClient_name(NULL);
$this->user->identity->save(false);

View file

@ -10,6 +10,7 @@ use WhichBrowser;
final class VKAPIPresenter extends OpenVKPresenter
{
protected $silent = true;
private function logRequest(string $object, string $method): void
{
$date = date(DATE_COOKIE);