I was getting a run-time error. Something like “assert is not a function of org.apache.royale.debugging.assertType”. When I looked it up [1] I saw that console.assert() was a js function, but I did now see window.assert() being a function.
If I remember correctly it was being called from XML.addInternalChildren() Feel free to change this if you think I made a mistake. [1] https://developer.mozilla.org/en-US/docs/Web/API/Console/assert From: Harbs<mailto:harbs.li...@gmail.com> Sent: Tuesday, October 27, 2020 6:55 PM To: dev@royale.apache.org<mailto:dev@royale.apache.org> Subject: Re: [royale-asjs] branch develop updated: Fix assertType for js Why was this necessary? > On Oct 27, 2020, at 5:55 PM, yish...@apache.org wrote: > > This is an automated email from the ASF dual-hosted git repository. > > yishayw pushed a commit to branch develop > in repository https://gitbox.apache.org/repos/asf/royale-asjs.git > > > The following commit(s) were added to refs/heads/develop by this push: > new 00c5b2a Fix assertType for js > 00c5b2a is described below > > commit 00c5b2ac31a1bbef87a7d388f1bc80476f6ff187 > Author: Yishay Weiss <yishayj...@hotmail.com> > AuthorDate: Tue Oct 27 15:54:49 2020 +0000 > > Fix assertType for js > --- > .../Core/src/main/royale/org/apache/royale/debugging/assertType.as | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git > a/frameworks/projects/Core/src/main/royale/org/apache/royale/debugging/assertType.as > > b/frameworks/projects/Core/src/main/royale/org/apache/royale/debugging/assertType.as > index 647c60f..27c28a2 100644 > --- > a/frameworks/projects/Core/src/main/royale/org/apache/royale/debugging/assertType.as > +++ > b/frameworks/projects/Core/src/main/royale/org/apache/royale/debugging/assertType.as > @@ -36,7 +36,7 @@ package org.apache.royale.debugging > COMPILE::JS > { > if(goog.DEBUG) > - assert((obj is type),message); > + console.assert((obj is type),message); > } > } > } >