mirror of
https://github.com/atom/atom.git
synced 2026-01-23 22:08:08 -05:00
Use getActivePath() helper from attach()
This commit is contained in:
@@ -25,8 +25,7 @@ class MarkdownPreview extends ScrollView
|
||||
@attach()
|
||||
|
||||
attach: ->
|
||||
path = rootView.getActiveEditor()?.getPath()
|
||||
return unless @isMarkdownFile(path)
|
||||
return unless @isMarkdownFile(@getActivePath())
|
||||
@rootView.append(this)
|
||||
@markdownBody.hide()
|
||||
@markdownSpinner.show()
|
||||
|
||||
Reference in New Issue
Block a user