mirror of
https://github.com/barsdeveloper/ueblueprint.git
synced 2026-02-04 08:50:33 +08:00
Fix infinitely recursive grammars
This commit is contained in:
@@ -201,7 +201,7 @@ export default class ObjectEntity extends IEntity {
|
||||
static grammar = this.createGrammar()
|
||||
|
||||
static createSubObjectGrammar() {
|
||||
return Parsernostrum.lazy(() => this.createGrammar())
|
||||
return Parsernostrum.lazy(() => this.grammar)
|
||||
.map(object =>
|
||||
values => values[Configuration.subObjectAttributeNameFromEntity(object)] = object
|
||||
)
|
||||
|
||||
@@ -50,7 +50,7 @@ export default class KeyboardShortcut extends IInput {
|
||||
return v
|
||||
}
|
||||
if (v.constructor === String) {
|
||||
const parsed = KeyBindingEntity.createGrammar().run(v)
|
||||
const parsed = KeyBindingEntity.grammar.run(v)
|
||||
if (parsed.status) {
|
||||
return parsed.value
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user