feat(workbench): improve traffic signal editing
This commit is contained in:
1 parent
00d5f7650f
commit
cf5bc0602b
3 files changed
+152
-23
No files matched your search
@@ -14,6 +14,7 @@ const SCHEMA = 'native-traffic-signals/v1';
|
||||
function loadOrGenerate(file, osmText, stopLines, intersections) {
|
||||
if (fs.existsSync(file)) {
|
||||
const document = JSON.parse(fs.readFileSync(file, 'utf8'));
|
||||
if (document?.provenance === 'empty') return generate(osmText, stopLines, intersections);
|
||||
try {
|
||||
return validateDocument(document, osmText);
|
||||
} catch (error) {
|
||||
|
||||
Reference in new issue
Block a user