From 2f8c232ed8c72374d04f1bffce3836008c27e48e Mon Sep 17 00:00:00 2001 From: Bill Thornton Date: Wed, 9 Dec 2020 12:32:24 -0500 Subject: [PATCH] Use the version from package.json in apphost --- package.json | 2 +- src/components/apphost.js | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 83dad17983..cc60f04d57 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "jellyfin-web", - "version": "0.0.0", + "version": "10.8.0", "description": "Web interface for Jellyfin", "repository": "https://github.com/jellyfin/jellyfin-web", "license": "GPL-2.0-or-later", diff --git a/src/components/apphost.js b/src/components/apphost.js index aefdee7340..0862867389 100644 --- a/src/components/apphost.js +++ b/src/components/apphost.js @@ -1,4 +1,4 @@ - +import { version } from '../../package.json'; import appSettings from '../scripts/settings/appSettings'; import browser from '../scripts/browser'; import { Events } from 'jellyfin-apiclient'; @@ -8,7 +8,6 @@ import globalize from '../scripts/globalize'; import profileBuilder from '../scripts/browserDeviceProfile'; const appName = 'Jellyfin Web'; -const appVersion = '10.7.0'; function getBaseProfileOptions(item) { const disableHlsVideoAudioCodecs = []; @@ -34,7 +33,7 @@ function getDeviceProfile(item, options = {}) { let profile; if (window.NativeShell) { - profile = window.NativeShell.AppHost.getDeviceProfile(profileBuilder, appVersion); + profile = window.NativeShell.AppHost.getDeviceProfile(profileBuilder, version); } else { const builderOpts = getBaseProfileOptions(item); profile = profileBuilder(builderOpts); @@ -370,7 +369,7 @@ export const appHost = { return window.NativeShell ? window.NativeShell.AppHost.appName() : appName; }, appVersion: function () { - return window.NativeShell ? window.NativeShell.AppHost.appVersion() : appVersion; + return window.NativeShell ? window.NativeShell.AppHost.appVersion() : version; }, getPushTokenInfo: function () { return {};