Fix major plugin version detection

pull/6449/head
Chocobozzz 2024-06-11 09:32:33 +02:00
parent cc0a39c2c4
commit 15f791edc0
No known key found for this signature in database
GPG Key ID: 583A612D890159BE
1 changed files with 2 additions and 2 deletions

View File

@ -208,8 +208,8 @@ export class PluginListInstalledComponent implements OnInit {
private isMajorUpgrade (plugin: PeerTubePlugin) { private isMajorUpgrade (plugin: PeerTubePlugin) {
if (!plugin.latestVersion) return false if (!plugin.latestVersion) return false
const latestMajor = plugin.latestVersion.split('.')[0] const latestMajor = parseInt(plugin.latestVersion.split('.')[0])
const currentMajor = plugin.version.split('.')[0] const currentMajor = parseInt(plugin.version.split('.')[0])
return latestMajor > currentMajor return latestMajor > currentMajor
} }