Skip to content

Commit

Permalink
add extra check to make sure gmail.js is initialized
Browse files Browse the repository at this point in the history
  • Loading branch information
Omar Qureshi committed Jul 19, 2015
1 parent ea27ae7 commit b6ada88
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ var pixelblock = (function(){
// add bootstrap.js
$('#bs-script').attr('src', $('#bs-script').attr('data-src'));
// init gmail.js
gmail = new Gmail();
gmail = Gmail();
}

var start = function(){
Expand All @@ -196,9 +196,9 @@ var pixelblock = (function(){
return {init:init, start:start};
})();

// check if jquery loaded & initialized
// check if jquery/gmail.js loaded & initialized
var checkLoaded = function() {
if(window.jQuery) {
if(window.jQuery && typeof Gmail != 'undefined') {
$.fn.onAvailable = function(e) {
var t = this.selector;
var n = this;
Expand Down

0 comments on commit b6ada88

Please sign in to comment.