mirror of
https://github.com/atom/atom.git
synced 2026-04-06 03:02:13 -04:00
Guard against null item like saveItem/saveItemAs does
This commit is contained in:
@@ -677,7 +677,7 @@ class Pane extends Model
|
||||
true
|
||||
|
||||
handleSaveError: (error, item) ->
|
||||
itemPath = error.path ? item.getPath?()
|
||||
itemPath = error.path ? item?.getPath?()
|
||||
addWarningWithPath = (message, options) ->
|
||||
message = "#{message} '#{itemPath}'" if itemPath
|
||||
atom.notifications.addWarning(message, options)
|
||||
|
||||
Reference in New Issue
Block a user