]> source.dussan.org Git - jquery.git/commitdiff
charAt -> string indexing. Close gh-1359.
authorMike Sidorov <mikes.ekb@gmail.com>
Thu, 12 Sep 2013 17:32:44 +0000 (12:32 -0500)
committerTimmy Willison <timmywillisn@gmail.com>
Thu, 12 Sep 2013 17:33:51 +0000 (12:33 -0500)
src/core/init.js
src/css.js

index e349bb61656cdb6338d709bfab7497da6e97e89d..daf5d1909416ff11a8651a7ec23ceb062e3370a0 100644 (file)
@@ -23,7 +23,7 @@ var rootjQuery,
 
                // Handle HTML strings
                if ( typeof selector === "string" ) {
-                       if ( selector.charAt(0) === "<" && selector.charAt( selector.length - 1 ) === ">" && selector.length >= 3 ) {
+                       if ( selector[0] === "<" && selector[ selector.length - 1 ] === ">" && selector.length >= 3 ) {
                                // Assume that strings that start and end with <> are HTML and skip the regex check
                                match = [ null, selector, null ];
 
index 79ab342d55d5815f45ffe424676fc66e343fe0a5..ee6a3935bd82f701b92483c4f7ae21c3378f683f 100644 (file)
@@ -46,7 +46,7 @@ function vendorPropName( style, name ) {
        }
 
        // check for vendor prefixed names
-       var capName = name.charAt(0).toUpperCase() + name.slice(1),
+       var capName = name[0].toUpperCase() + name.slice(1),
                origName = name,
                i = cssPrefixes.length;