mirror of
https://github.com/atom/atom.git
synced 2026-02-05 20:25:04 -05:00
Ignore first modified event in config editor
This event comes from initially setting the text for the current config value on the editor and was causing the config to be immediately saved multiple times when opened.
This commit is contained in:
@@ -48,5 +48,6 @@ class ConfigPanel extends View
|
||||
value ?= ""
|
||||
editor.setText(value.toString())
|
||||
|
||||
editor.getBuffer().on 'contents-modified', =>
|
||||
config.set(name, @parseValue(type, editor.getText()))
|
||||
editor.getBuffer().one 'contents-modified', =>
|
||||
editor.getBuffer().on 'contents-modified', =>
|
||||
config.set(name, @parseValue(type, editor.getText()))
|
||||
|
||||
Reference in New Issue
Block a user