mirror of
https://github.com/atom/atom.git
synced 2026-01-23 13:58:08 -05:00
Fall back to .serialize() if a pane item has no .getState() method
This commit is contained in:
@@ -33,7 +33,7 @@ class Pane extends View
|
||||
@items = args
|
||||
@state = telepath.Document.create
|
||||
deserializer: 'Pane'
|
||||
items: @items.map (item) -> item.getState()
|
||||
items: @items.map (item) -> item.getState?() ? item.serialize()
|
||||
|
||||
@state.get('items').on 'changed', ({index, removed, inserted, site}) =>
|
||||
return if site is @state.site.id
|
||||
|
||||
Reference in New Issue
Block a user