Yes. We added it. I suppose we can return the parameter.

> On Aug 27, 2017, at 8:18 AM, Alex Harui <aha...@adobe.com.INVALID> wrote:
> 
> setAttribute is not showing up in the spec for me.  Is it one of the
> methods internal to the implementation?  If so, can it return the value it
> receives instead of null?
> 
> -Alex
> 
> On 8/26/17, 11:41 AM, "Harbs" <harbs.li...@gmail.com> wrote:
> 
>> I just ran into the following issue:
>> 
>> I have some code which looks like this:
>> ID = _rawStoryXML.@Self = UIDUtil.createUID();
>> 
>> It gets cross-compiled in JS to this:
>> this.ID = 
>> org.apache.flex.utils.Language.string(this._rawStoryXML.setAttribute('Self
>> ', org.apache.flex.utils.UIDUtil.createUID()));
>> 
>> The problem is that both ID and _rawStoryXML.@Self should both be
>> assigned the result of UIDUtil.createUID().
>> 
>> Instead, ID is being assigned the result of
>> this._rawStoryXML.setAttribute('Self',
>> org.apache.flex.utils.UIDUtil.createUID()) which happens to be null.
>> 
>> I’m not sure how to fix this issue. Maybe it’s necessary to assign a
>> temporary variable and then assign both values separately:
>> 
>> var tempVal = org.apache.flex.utils.UIDUtil.createUID();
>> this._rawStoryXML.setAttribute('Self', tempVal);
>> this.ID = tempVal;
>> 
>> (or something like that)
>> 
>> Harbs
> 

Reply via email to