mirror of
				https://github.com/node-red/node-red.git
				synced 2025-03-01 10:36:34 +00:00 
			
		
		
		
	Fix handling of default workflow mode when projects not active
This commit is contained in:
		| @@ -580,11 +580,13 @@ function saveFlows(flows, user) { | ||||
|     } | ||||
|     return util.writeFile(flowsFullPath, flowData, flowsFileBackup).then(() => { | ||||
|         var gitSettings = getUserGitSettings(user) || {}; | ||||
|         var workflowMode = (gitSettings.workflow||{}).mode || settings.editorTheme.projects.workflow.mode; | ||||
|         if (activeProject && workflowMode === 'auto') { | ||||
|             return activeProject.stageFile([flowsFullPath, credentialsFile]).then(() => { | ||||
|                 return activeProject.commit(user,{message:"Update flow files"}) | ||||
|             }) | ||||
|         if (activeProject) { | ||||
|             var workflowMode = (gitSettings.workflow||{}).mode || settings.editorTheme.projects.workflow.mode; | ||||
|             if (workflowMode === 'auto') { | ||||
|                 return activeProject.stageFile([flowsFullPath, credentialsFile]).then(() => { | ||||
|                     return activeProject.commit(user,{message:"Update flow files"}) | ||||
|                 }) | ||||
|             } | ||||
|         } | ||||
|     }); | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user