@@ -25,25 +25,25 @@ var PackageService = (function () {
25
25
project :{ } ,
26
26
chapters :[ ]
27
27
} ;
28
- this . config = { } ;
28
+ this . packageJson = null ;
29
29
}
30
30
PackageService . prototype . selectPackage = function ( packageName ) {
31
31
var packagePath = path_1 . join ( window . coderoad . dir , 'node_modules' , packageName ) ;
32
- this . config = require ( path_1 . join ( packagePath , 'package.json' ) ) ;
33
- store_1 . store . dispatch ( actions_1 . setGlobals ( this . config ) ) ;
34
- this . data = require ( path_1 . join ( packagePath , this . config . main ) ) ;
32
+ this . packageJson = require ( path_1 . join ( packagePath , 'package.json' ) ) ;
33
+ store_1 . store . dispatch ( actions_1 . setGlobals ( this . packageJson ) ) ;
34
+ this . data = require ( path_1 . join ( packagePath , this . packageJson . main ) ) ;
35
35
this . packageName = packageName ;
36
36
} ;
37
37
PackageService . prototype . page = function ( _a ) {
38
38
var chapter = _a . chapter , page = _a . page ;
39
39
return cloneDeep ( this . data . chapters [ chapter ] . pages [ page ] ) ;
40
40
} ;
41
- PackageService . prototype . getConfig = function ( ) {
42
- return this . config ;
41
+ PackageService . prototype . getPackage = function ( ) {
42
+ return this . packageJson ;
43
43
} ;
44
44
PackageService . prototype . configTaskTests = function ( tasks ) {
45
45
var _this = this ;
46
- var config = this . config . config ;
46
+ var config = this . packageJson . config ;
47
47
return ! tasks ?[ ] :tasks . map ( function ( task ) {
48
48
if ( task . tests ) {
49
49
task . tests = task . tests . map ( function ( test ) {