diff --git a/ApiClient.js b/ApiClient.js index 8b602610a0..3117b4b006 100644 --- a/ApiClient.js +++ b/ApiClient.js @@ -10,8 +10,9 @@ MediaBrowser.ApiClient = function ($, navigator, JSON, WebSocket, setTimeout) { * @param {String} serverHostName * @param {String} serverPortNumber * @param {String} clientName + * @param {String} applicationVersion */ - return function (serverProtocol, serverHostName, serverPortNumber, clientName) { + return function (serverProtocol, serverHostName, serverPortNumber, clientName, applicationVersion) { if (!serverProtocol) { throw new Error("Must supply a serverProtocol, e.g. http:"); @@ -120,7 +121,7 @@ MediaBrowser.ApiClient = function ($, navigator, JSON, WebSocket, setTimeout) { if (clientName) { - var auth = 'MediaBrowser Client="' + clientName + '", Device="' + deviceName + '", DeviceId="' + deviceId + '"'; + var auth = 'MediaBrowser Client="' + clientName + '", Device="' + deviceName + '", DeviceId="' + deviceId + '", Version="' + applicationVersion + '"'; if (currentUserId) { auth += ', UserId="' + currentUserId + '"'; @@ -3277,11 +3278,11 @@ MediaBrowser.ApiClient = function ($, navigator, JSON, WebSocket, setTimeout) { /** * Provides a friendly way to create an api client instance using information from the browser's current url */ -MediaBrowser.ApiClient.create = function (clientName) { +MediaBrowser.ApiClient.create = function (clientName, applicationVersion) { var loc = window.location; - return new MediaBrowser.ApiClient(loc.protocol, loc.hostname, loc.port, clientName); + return new MediaBrowser.ApiClient(loc.protocol, loc.hostname, loc.port, clientName, applicationVersion); }; /** diff --git a/dashboard-ui/scripts/dashboardpage.js b/dashboard-ui/scripts/dashboardpage.js index 8a17becdec..4abae6da46 100644 --- a/dashboard-ui/scripts/dashboardpage.js +++ b/dashboard-ui/scripts/dashboardpage.js @@ -94,7 +94,9 @@ html += ''; html += '