Browse files

Don't show content on redirect

  • Loading branch information...
1 parent 57d972e commit 4921f68476a702859bd5d8082e93c22110d2ef36 @lackac committed Apr 26, 2009
Showing with 5 additions and 5 deletions.
  1. +5 −5 javascripts/jquery.gadgeteer.js
View
10 javascripts/jquery.gadgeteer.js
@@ -87,14 +87,14 @@ $.gadgeteer = function(callback, options) {
// Do another adjustHeight in 250ms just to be sure
setTimeout(function() {$(window).adjustHeight();}, 250);
}).ajaxError(function(e, request, settings, exception) {
- if (settings.target) {
+ if (settings.target && request.status.toString().charAt(0) != '3') {
var html = request.responseText;
$(settings.target).html(html);
+ // !iframe
+ $(window).adjustHeight();
+ // Do another adjustHeight in 250ms just to be sure
+ setTimeout(function() {$(window).adjustHeight();}, 250);
}
- // !iframe
- $(window).adjustHeight();
- // Do another adjustHeight in 250ms just to be sure
- setTimeout(function() {$(window).adjustHeight();}, 250);
}).ajaxComplete(function(e, request, settings) {
if (request.status.toString().charAt(0) == '3') {
var href = request.getResponseHeader('Location') || request.getResponseHeader('location');

0 comments on commit 4921f68

Please sign in to comment.