diff --git a/config.template.php b/config.template.php
index fe88d5134b748dc385685ab7803d28d303380bd3..5c8fe7c9cca78fdc3d29f1fc16a2663527f59a4c 100644
--- a/config.template.php
+++ b/config.template.php
@@ -175,8 +175,5 @@ if(isset($default_timezone) && function_exists('date_default_timezone_set')) {
 //Set the default layout 
 $default_layout = 'v7';
 
-//Maximiun scheduled workflows default value set to 10
-$max_scheduled_workflows = 10;
-
 include_once 'config.security.php';
 ?>
diff --git a/modules/com_vtiger_workflow/VTWorkflowManager.inc b/modules/com_vtiger_workflow/VTWorkflowManager.inc
index e5c9d972ba8f5a162157cb2e7f8b866651c350cc..0ea8f1235af3b2a4337ded33ab62b9e1dc936f2f 100644
--- a/modules/com_vtiger_workflow/VTWorkflowManager.inc
+++ b/modules/com_vtiger_workflow/VTWorkflowManager.inc
@@ -111,8 +111,8 @@ class VTWorkflowManager{
 	 * @return int
 	 */
 	function getMaxAllowedScheduledWorkflows() {
-        global $max_scheduled_workflows;
-		return $max_scheduled_workflows;
+            vglobal('max_scheduled_workflows', 10);
+            return vglobal('max_scheduled_workflows');
 	}
 
 	function getWorkflowsForModule($moduleName){