avm1: Disallow setting "" property

object[""] has no effect.
This commit is contained in:
Mike Welsh 2020-06-27 19:21:28 -07:00
parent ef82fc472e
commit ecc54d01f7
1 changed files with 1 additions and 1 deletions

View File

@ -201,7 +201,7 @@ impl<'gc> ScriptObject<'gc> {
self.0.write(context.gc_context).prototype = Some(value.coerce_to_object(avm, context));
} else if let Ok(index) = name.parse::<usize>() {
self.set_array_element(index, value.to_owned(), context.gc_context);
} else {
} else if !name.is_empty() {
if name == "length" {
let length = value
.coerce_to_f64(avm, context)