1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Remember to disable projects in editor when git not found

This commit is contained in:
Nick O'Leary 2018-02-01 20:35:18 +00:00
parent 6f69995f4e
commit 67d7930aef
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9

View File

@ -95,6 +95,14 @@ function init(_settings, _runtime) {
if (!gitConfig) {
projectLogMessages.push(log._("storage.localfilesystem.projects.git-not-found"))
projectsEnabled = false;
try {
// As projects have to be turned on, we know this property
// must exist at this point, so turn it off.
// TODO: when on-by-default, this will need to do more
// work to disable.
settings.editorTheme.projects.enabled = false;
} catch(err) {
}
} else {
globalGitUser = gitConfig.user;
Projects.init(settings,runtime);