From bd7865a748e1ec2c992298fef42d39e34af875cf Mon Sep 17 00:00:00 2001 From: Matthai Kurian <matthai.kurian@frentix.com> Date: Tue, 17 Apr 2012 14:53:43 +0200 Subject: [PATCH] OO-221: corrected initialization of VersionSettingsForm --- src/main/java/org/olat/admin/version/VersionSettingsForm.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/java/org/olat/admin/version/VersionSettingsForm.java b/src/main/java/org/olat/admin/version/VersionSettingsForm.java index 20c0121a42f..76b7a062574 100644 --- a/src/main/java/org/olat/admin/version/VersionSettingsForm.java +++ b/src/main/java/org/olat/admin/version/VersionSettingsForm.java @@ -79,8 +79,10 @@ public class VersionSettingsForm extends FormBasicController { Long maxNumber = getNumOfVersions(); if(maxNumber == null) { numOfVersions.select("0", true); + } else if (maxNumber.longValue() == 0l) { + numOfVersions.select("0", true); // deactivated } else if (maxNumber.longValue() == -1l) { - numOfVersions.select("-1", true); + numOfVersions.select("-1", true); // unlimited } else { String str = maxNumber.toString(); boolean found = false; -- GitLab