This project is archived and is in readonly mode.

#391 ✓invalid

$type returns "object" for Array in Adobe AIR

Reported by thynctank | September 22nd, 2008 @ 10:07 PM | in 1.2.2

Simple as that. If I run $type([1,2,3]) in browser (including Safari) I get "array" but in AIR I get "object".

Using typeof works fine.

Comments and changes to this ticket

  • thynctank

    thynctank September 22nd, 2008 @ 10:08 PM

    attached image shows output of $type w/ different data types

  • Jan Kassens

    Jan Kassens December 2nd, 2008 @ 08:13 AM

    • Milestone changed from 2.0 to 1.2.2
    • State changed from “new” to “open”
    • Assigned user changed from “Valerio” to “Jan Kassens”

    thanks will look into it.

  • Taracque

    Taracque December 2nd, 2008 @ 11:52 AM

    for me typeof [1,2,3] also returns object in Air 1.5 (tried typeof new Array(), typeof [] and several other, all returns object in introspector)

  • Taracque

    Taracque December 2nd, 2008 @ 12:37 PM

    after some reading that typeof should returns "object" for arrays, so the problem maybe, that obj.$ is not exists for arrays…

  • Jan Kassens

    Jan Kassens December 2nd, 2008 @ 12:42 PM

    • State changed from “open” to “invalid”

    The MooTools prototypes are for some reason not assigned to objects created in the introspector, using a simple alert($type([])); in the application js alerts 'array'. I guess nothing we can do about that.

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

Shared Ticket Bins

People watching this ticket