Skip to content

Commit

Permalink
Fix for IE 8/9: Only initialize Stack, if Stack is Present. Fixes bug…
Browse files Browse the repository at this point in the history
… where making 'internal links' was broken.
  • Loading branch information
bobdenotter committed May 15, 2014
1 parent 75b6430 commit ca0bb0c
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions app/view/js/bolt.js
Expand Up @@ -114,7 +114,11 @@ jQuery(function($) {

files = new Files();

stack = new Stack();
// If we have a 'stackholder' on the page, bind the uploader and file-selector.
if ($('#stackholder').is('*')) {
stack = new Stack();
}


});

Expand Down Expand Up @@ -653,15 +657,8 @@ var Stack = Backbone.Model.extend({
defaults: {
},

/**
* If we have a 'stackholder' on the page, bind the uploader and file-selector.
*/
initialize: function() {

if ($('#stackholder').is('*')) {
this.bindEvents();
}

this.bindEvents();
},

bindEvents: function() {
Expand Down

0 comments on commit ca0bb0c

Please sign in to comment.