mirror of
https://github.com/TangentFoxy/semver.lua.git
synced 2025-07-28 02:52:21 +00:00
@@ -173,6 +173,7 @@ end
|
|||||||
-- if a and b are versions, a ^ b means "b is backwards-compatible with a"
|
-- if a and b are versions, a ^ b means "b is backwards-compatible with a"
|
||||||
-- in other words, "it's safe to upgrade from a to b"
|
-- in other words, "it's safe to upgrade from a to b"
|
||||||
function mt:__pow(other)
|
function mt:__pow(other)
|
||||||
|
if self.major == 0 then return false end
|
||||||
return self.major == other.major and
|
return self.major == other.major and
|
||||||
self.minor <= other.minor
|
self.minor <= other.minor
|
||||||
end
|
end
|
||||||
|
Reference in New Issue
Block a user