I have some JSOM code in my master page(seattle.master). The code runs until load() method on the context object but executeQueryAsync is not executing.
SP.SOD.executeOrDelayUntilScriptLoaded(function(){
var context = SP.ClientContext.get_current();
var web = context.get_web();
var list = web.get_lists().getByTitle(list_title);
context.load(list);
context.executeQueryAsync(function(data){
console.log(data);
},
function(data,args){
console.log(args);
});
},'sp.js');
Neither of the log statements in the success nor the error function is getting printed.
Thanks!
getByTitlesomewhere - is it just hidden in this question?