Sequencing 2 lines of JQUERY
- by nobosh
I have the following lines of JQUERY:
// When dragging ends
stop: function(event, ui) {
// Replace the placeholder with the original
$placeholder.after( $this.show() ).remove();
// Run a custom stop function specitifed in the settings
settings.stop.apply(this);
},
I don't want settings.stop.apply(this); to run UNTIL the line above is $placeholder.after( $this.show() ).remove();, right now what's happening is the settings.stop is running to early.
With JQUERY, how can I Sequence these two lines to not proceed until the first is complete?
Thanks