summaryrefslogtreecommitdiffstats
path: root/utils/src/ooinstall/variants.py
diff options
context:
space:
mode:
Diffstat (limited to 'utils/src/ooinstall/variants.py')
-rw-r--r--utils/src/ooinstall/variants.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/utils/src/ooinstall/variants.py b/utils/src/ooinstall/variants.py
index 05281d654..3bb61dddb 100644
--- a/utils/src/ooinstall/variants.py
+++ b/utils/src/ooinstall/variants.py
@@ -29,6 +29,9 @@ class Variant(object):
self.versions = versions
+ def latest_version(self):
+ return self.versions[-1]
+
# WARNING: Keep the versions ordered, most recent last:
OSE = Variant('openshift-enterprise', 'OpenShift Enterprise',
@@ -58,7 +61,7 @@ def find_variant(name, version=None):
for prod in SUPPORTED_VARIANTS:
if prod.name == name:
if version is None:
- return (prod, prod.versions[-1])
+ return (prod, prod.latest_version())
for v in prod.versions:
if v.name == version:
return (prod, v)