forked from MapComplete/MapComplete
chore: automated housekeeping...
This commit is contained in:
parent
c9ce29f206
commit
40e894df8b
294 changed files with 14209 additions and 4192 deletions
|
|
@ -33,9 +33,20 @@ export default class DependencyCalculator {
|
|||
*/
|
||||
public static getLayerDependencies(
|
||||
layer: LayerConfig
|
||||
): { neededLayer: string; reason: string; context?: string; neededBy: string, checkHasSnapName: boolean }[] {
|
||||
const deps: { neededLayer: string; reason: string; context?: string; neededBy: string, checkHasSnapName: boolean }[] =
|
||||
[]
|
||||
): {
|
||||
neededLayer: string
|
||||
reason: string
|
||||
context?: string
|
||||
neededBy: string
|
||||
checkHasSnapName: boolean
|
||||
}[] {
|
||||
const deps: {
|
||||
neededLayer: string
|
||||
reason: string
|
||||
context?: string
|
||||
neededBy: string
|
||||
checkHasSnapName: boolean
|
||||
}[] = []
|
||||
|
||||
for (let i = 0; layer.presets !== undefined && i < layer.presets.length; i++) {
|
||||
const preset = layer.presets[i]
|
||||
|
|
@ -51,7 +62,7 @@ export default class DependencyCalculator {
|
|||
reason: `preset \`${preset.title.textFor("en")}\` snaps to this layer`,
|
||||
context: `${layer.id}.presets[${i}]`,
|
||||
neededBy: layer.id,
|
||||
checkHasSnapName: true
|
||||
checkHasSnapName: true,
|
||||
})
|
||||
})
|
||||
}
|
||||
|
|
@ -63,7 +74,7 @@ export default class DependencyCalculator {
|
|||
reason: "a tagrendering needs this layer",
|
||||
context: tr.id,
|
||||
neededBy: layer.id,
|
||||
checkHasSnapName: false
|
||||
checkHasSnapName: false,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
|
@ -99,7 +110,7 @@ export default class DependencyCalculator {
|
|||
"] which calculates the value for " +
|
||||
currentKey,
|
||||
neededBy: layer.id,
|
||||
checkHasSnapName: false
|
||||
checkHasSnapName: false,
|
||||
})
|
||||
|
||||
return []
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue