Last active
August 29, 2015 14:00
-
-
Save nategraves/88d250541d141f4e120b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var _boards = null; | |
var setBoards = function(boards) { | |
_boards = boards; | |
} | |
var getBoards = function() { | |
Trello.get( | |
'/members/me', | |
{boards:"open",organizations:"all"}, | |
function(data) { | |
setBoards(data.boards); | |
}, | |
function(xhr){ | |
if (xhr.status == 401) { | |
Trello.deauthorize(); | |
Trello.authorize(); | |
} else { | |
$("#view").html("<h1>Connection to Trello API is broken, Please <a href='javascript:reload();'>Reload</a></h1>"); | |
} | |
} | |
); | |
}; |
danielmcgrath
commented
Apr 30, 2014
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment