mirror of
https://github.com/asphyxia-core/plugins.git
synced 2026-03-21 17:34:46 -05:00
Merge pull request #29 from DitFranXX/fix-version-check
fix: 🐛 Fix if major version bump up to 2.0
This commit is contained in:
commit
732d5ee6dc
|
|
@ -15,7 +15,7 @@ export function isRequiredCoreVersion(major: number, minor: number) {
|
|||
// version value exposed since Core v1.19
|
||||
const core_major = typeof CORE_VERSION_MAJOR === "number" ? CORE_VERSION_MAJOR : 1
|
||||
const core_minor = typeof CORE_VERSION_MINOR === "number" ? CORE_VERSION_MINOR : 18
|
||||
return core_major >= major && core_minor >= minor
|
||||
return core_major > major || (core_major === major && core_minor >= minor)
|
||||
};
|
||||
|
||||
export function isAsphyxiaDebugMode() {
|
||||
|
|
|
|||
|
|
@ -7,5 +7,5 @@ export function isRequiredVersion(major: number, minor: number) {
|
|||
// version value exposed since Core v1.19
|
||||
const core_major = typeof CORE_VERSION_MAJOR === "number" ? CORE_VERSION_MAJOR : 1
|
||||
const core_minor = typeof CORE_VERSION_MINOR === "number" ? CORE_VERSION_MINOR : 18
|
||||
return core_major >= major && core_minor >= minor
|
||||
return core_major > major || (core_major === major && core_minor >= minor)
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user