Use the native Array indexOf method if it exists, for jQuery.inArray.