瀏覽代碼

LibJS: Fix logic typo in ArgumentsObject.[[Set]]

Thanks to Linus for spotting this! :^)
Andreas Kling 4 年之前
父節點
當前提交
7fdeb0ec74
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      Userland/Libraries/LibJS/Runtime/ArgumentsObject.cpp

+ 1 - 1
Userland/Libraries/LibJS/Runtime/ArgumentsObject.cpp

@@ -57,7 +57,7 @@ bool ArgumentsObject::internal_set(PropertyName const& property_name, Value valu
     bool is_mapped = false;
 
     // 1. If SameValue(args, Receiver) is false, then
-    if (same_value(this, receiver)) {
+    if (!same_value(this, receiver)) {
         // a. Let isMapped be false.
         is_mapped = false;
     } else {