This commit is contained in:
Pablo Ferreiro 2022-03-12 00:34:42 +01:00
parent 9c95620384
commit 7ba324c935
No known key found for this signature in database
GPG key ID: 41FBCE65B779FA24
2 changed files with 3 additions and 5 deletions

View file

@ -78,8 +78,8 @@ class Misc {
}
// Legacy mode
$legacy = self::env('FORCE_LEGACY', false); // Instance level
$_COOKIE['enable_legacy'] ?? $legacy = true; // User level
$legacy = self::env('FORCE_LEGACY', false); // Instance level (has priority over user)
return $legacy === false ? new \TikScraper\Api($options, $cacheEngine) : new \TikScraper\Legacy($options, $cacheEngine);
}