Side navigation
#15090 closed bug (migrated)
Opened May 13, 2014 08:18AM UTC
Closed October 21, 2014 12:42AM UTC
$.isPlainObject returns true for instance of $.Event
Reported by: | San4esZ | Owned by: | |
---|---|---|---|
Priority: | low | Milestone: | 2.2 |
Component: | event | Version: | 2.1.1 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
Compare http://jsfiddle.net/San4es/Tkgt3/ and http://jsfiddle.net/San4es/Cst6V/. Seems, that $.isPlainObject($.Event('click')) should return false in both samples.
Use case http://jsfiddle.net/San4es/pA6Cd/ - jQuery 2.x breaks $.Event instance.
Attachments (0)
Change History (2)
Changed May 13, 2014 02:13PM UTC by comment:1
component: | core → event |
---|---|
milestone: | 2.next → 2.2 |
priority: | undecided → low |
status: | new → open |
Changed October 21, 2014 12:42AM UTC by comment:2
resolution: | → migrated |
---|---|
status: | open → closed |
Migrated to https://github.com/jquery/jquery/issues/1771
The docs say:
So expecting anything to maintain its constructedness in a deep-extend is not a good assumption.
However, the
event
object does seem to pass the.isPlainObject()
test which seems wrong.http://jsfiddle.net/pA6Cd/3/