fixing auto pretty only on json files
This commit is contained in:
parent
7b7ca7b4c1
commit
d27edae3c0
|
@ -28,7 +28,7 @@ class PrettyJsonLintListener(sublime_plugin.EventListener, PrettyJsonBaseCommand
|
|||
|
||||
|
||||
class PrettyJsonAutoPrettyOnSaveListener(sublime_plugin.EventListener):
|
||||
def on_pre_save(self, edit):
|
||||
def on_pre_save(self, view):
|
||||
auto_pretty = s.get("pretty_on_save", False)
|
||||
if auto_pretty:
|
||||
if auto_pretty and "JSON" in view.settings().get('syntax'):
|
||||
sublime.active_window().run_command('pretty_json')
|
||||
|
|
Loading…
Reference in New Issue