fix isRelease and isDebug, do not take of position of 'release' in [a,b] = getversion... 80/16880/2
Antoine ELIAS [Thu, 23 Jul 2015 07:43:44 +0000 (09:43 +0200)]
Change-Id: I7d8dd49c2ed60133acc473beaf9bcd0379a945ad

scilab/modules/core/macros/isRelease.sci

index 5b1a896..d0c41e9 100644 (file)
@@ -6,9 +6,10 @@
 // =============================================================================
 function ret = isRelease()
     [a,b] = getversion();
-    if or(getscilabmode() == ["NWNI", "SCILAB_API"]) then
-        ret = b(4) == "release";
-    else
-        ret = b(5) == "release";
+    idx = find(b == "release");
+    ret = %t;
+
+    if isempty(idx) then
+        ret = %f;
     end
 endfunction