mirror of
https://github.com/jquery/jquery.git
synced 2026-01-25 18:18:05 -05:00
Return control of $ and jQuery only if it is really necessary. This make
jQuery.noConflict() callable anytime.
This commit is contained in:
@@ -373,9 +373,9 @@ jQuery.extend = jQuery.fn.extend = function() {
|
||||
|
||||
jQuery.extend({
|
||||
noConflict: function( deep ) {
|
||||
window.$ = _$;
|
||||
if ( window.$ === jQuery ) window.$ = _$;
|
||||
|
||||
if ( deep ) {
|
||||
if ( deep && window.jQuery === jQuery ) {
|
||||
window.jQuery = _jQuery;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user