]> source.dussan.org Git - jquery.git/commitdiff
No ticket: Move property descriptor assignment to save a byte. Close gh-1188.
authorstonelee <istonelee@gmail.com>
Fri, 1 Mar 2013 04:33:37 +0000 (12:33 +0800)
committerRichard Gibson <richard.gibson@gmail.com>
Thu, 14 Mar 2013 13:53:19 +0000 (09:53 -0400)
src/data.js

index dfd8555a0376b8610d9c671685fbf7129f12cf86..585d78b20912dde84045ad90434c95fd52bec6bc 100644 (file)
@@ -29,10 +29,10 @@ Data.prototype = {
                // If not, create one
                if ( !unlock ) {
                        unlock = Data.uid++;
-                       descriptor[ this.expando ] = { value: unlock };
 
                        // Secure it in a non-enumerable, non-writable property
                        try {
+                               descriptor[ this.expando ] = { value: unlock };
                                Object.defineProperties( owner, descriptor );
 
                        // Support: Android<4