Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#14253 closed defect (fixed)

Stateful#set() doesn't check for own properties on object names

Reported by: Mark Wubben Owned by: Kris Zyp
Priority: high Milestone: 1.8
Component: Core Version: 1.7.0
Keywords: Cc:
Blocked By: Blocking:

Description

If an object is passed to Stateful#set() all properties in that object are set on the stateful. This is done via a naïve for/in loop that does not use hasOwnProperty(). As a result you can't pass other stateful objects.

A patch is in <https://github.com/EqualMedia/dojo/commit/a2e5ac51bb142b3c3eee8bddc7eec5e1e19175be>. Any nasty side-effects this might have?

Change History (5)

comment:1 Changed 8 years ago by bill

Cc: Kris Zyp removed
Owner: set to Kris Zyp

comment:2 Changed 8 years ago by bill

Milestone: tbd

comment:3 Changed 8 years ago by Kris Zyp

Resolution: fixed
Status: newclosed

In [27488]:

Check for own property, make sure we can set a Stateful from another Stateful, fixes #14253 !strict

comment:4 Changed 8 years ago by bill

Milestone: tbd1.8

comment:5 Changed 8 years ago by Kris Zyp

In [27508]:

Back out unintended changes from [27488], refs #14253 !strict

Note: See TracTickets for help on using tickets.