Provide type from package

This prevents packages from needing instance of checks for package
class type
This commit is contained in:
Kevin Sawicki 2013-09-18 10:20:46 -07:00
parent 32556b0ce6
commit 49647ffc58
2 changed files with 4 additions and 0 deletions

View File

@ -24,6 +24,8 @@ class AtomPackage extends Package
resolvedMainModulePath: false
mainModule: null
getType: -> 'atom'
load: ->
try
@metadata = Package.loadMetadata(@path)

View File

@ -26,6 +26,8 @@ class TextMatePackage extends Package
@scopedProperties = []
@metadata = {@name}
getType: -> 'textmate'
load: ({sync}={}) ->
@metadata = Package.loadMetadata(@path, true)