From 1cca969c3cbf83f17f947a022a3b315e26add89f Mon Sep 17 00:00:00 2001 From: =?utf8?q?Scott=20Gonz=C3=A1lez?= Date: Mon, 23 Aug 2010 15:35:49 -0400 Subject: [PATCH] Widget: Refactored code for re-initialization to reduce file size. --- ui/jquery.ui.widget.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ui/jquery.ui.widget.js b/ui/jquery.ui.widget.js index e21287ae0..ead4af12b 100644 --- a/ui/jquery.ui.widget.js +++ b/ui/jquery.ui.widget.js @@ -99,10 +99,7 @@ $.widget.bridge = function( name, object ) { this.each(function() { var instance = $.data( this, name ); if ( instance ) { - if ( options ) { - instance.option( options ); - } - instance._init(); + instance.option( options || {} )._init(); } else { $.data( this, name, new object( options, this ) ); } -- 2.39.5