From 6704ae5da427fa41ab0be52555269dfdabe50c90 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Mon, 11 Oct 2021 22:18:38 +0200 Subject: [PATCH] Upgrade to deal with multiple soolutions --- Platform/Client/httpInterface.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/Platform/Client/httpInterface.js b/Platform/Client/httpInterface.js index d3a392d2b..7c1237bb3 100644 --- a/Platform/Client/httpInterface.js +++ b/Platform/Client/httpInterface.js @@ -1009,6 +1009,7 @@ exports.newHttpInterface = function newHttpInterface() { let directoryCount = 0 let allAppSchemas = [] let allAppSchemasFilePaths = [] + let allAppSchemasFileProjects = [] for (let i = 0; i < projects.length; i++) { let project = projects[i] @@ -1044,6 +1045,7 @@ exports.newHttpInterface = function newHttpInterface() { SCHEMA_MAP.set(schemaDocument.type, schemaDocument) allAppSchemas.push(schemaDocument) allAppSchemasFilePaths.push(fileToRead) + allAppSchemasFileProjects.push(project) } catch (err) { console.log('[ERROR] sendSchema -> Error Parsing JSON File: ' + fileToRead + ' .Error = ' + err.stack) return @@ -1088,6 +1090,14 @@ exports.newHttpInterface = function newHttpInterface() { hits++ foundProject = project multiProject = multiProject + ' -> ' + project + + let fileProject = allAppSchemasFileProjects[i] + //console.log(fileProject, project) + if (fileProject === project) { + /* If the projec of the file is the same as the project found, then we consider this a match*/ + hits = 1 + continue + } } }