diff --git a/static/js/services/buddylist.js b/static/js/services/buddylist.js index a95673a5..4efa779e 100644 --- a/static/js/services/buddylist.js +++ b/static/js/services/buddylist.js @@ -18,7 +18,7 @@ * along with this program. If not, see . * */ -define(['underscore', 'modernizr', 'jquery', 'avltree', 'text!partials/buddy.html', 'text!partials/buddyactions.html', 'text!partials/buddyactionsforaudiomixer.html', 'rAF'], function(_, Modernizr, $, AvlTree, templateBuddy, templateBuddyActions, templateBuddyActionsForAudioMixer) { +define(['underscore', 'modernizr', 'avltree', 'text!partials/buddy.html', 'text!partials/buddyactions.html', 'text!partials/buddyactionsforaudiomixer.html', 'rAF'], function(_, Modernizr, AvlTree, templateBuddy, templateBuddyActions, templateBuddyActionsForAudioMixer) { var BuddyTree = function() { @@ -110,7 +110,7 @@ define(['underscore', 'modernizr', 'jquery', 'avltree', 'text!partials/buddy.htm }; // buddyList - return ["$window", "$compile", "playSound", "buddyData", "fastScroll", function ($window, $compile, playSound, buddyData, fastScroll) { + return ["$window", "$compile", "playSound", "buddyData", "fastScroll", "mediaStream", function ($window, $compile, playSound, buddyData, fastScroll, mediaStream) { var requestAnimationFrame = $window.requestAnimationFrame; @@ -122,9 +122,6 @@ define(['underscore', 'modernizr', 'jquery', 'avltree', 'text!partials/buddy.htm var doc = $window.document; var buddyCount = 0; - var globalcontext = $("#globalcontext").text(); - var context = JSON.parse(globalcontext); - var Buddylist = function($element, $scope, opts) { this.$scope = $scope; @@ -326,7 +323,7 @@ define(['underscore', 'modernizr', 'jquery', 'avltree', 'text!partials/buddy.htm // can use data: urls directly return url; } else if (url.indexOf("img:") === 0) { - return context.Cfg.B + "img/buddy/"+url.substr(4); + return mediaStream.config.B + "img/buddy/"+url.substr(4); } console.log("Unknown buddy picture url", url);