mirror of
https://github.com/horsicq/Detect-It-Easy.git
synced 2026-06-24 01:54:08 +00:00
Add temporary Wayback guard in _setLang
Add a short-term compatibility check in db/language::_setLang to support legacy Wayback calls: if version is the boolean false, the function returns null and aborts further processing. Comment notes this is temporary and will be removed.
This commit is contained in:
parent
e8349e0db8
commit
11169a42e9
1 changed files with 5 additions and 0 deletions
|
|
@ -15,6 +15,11 @@ function _isLangDetected() {
|
|||
}
|
||||
|
||||
function _setLang(languageName, version) {
|
||||
// WAYBACK SUPPORT; WILL BE REMOVED.
|
||||
if (typeof version === "boolean" && !version) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// if "C/C++" already detected
|
||||
if (_isLangPresent("C/C++") && (languageName == "C" || languageName == "C++")) {
|
||||
_removeResult("language", "C/C++");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue