Skip to content

Commit 98a3430

Browse files
celliott181filipesilva
authored andcommitted
fix(@angular/cli): don't load old ember config
Close angular#4057
1 parent fce9f18 commit 98a3430

File tree

1 file changed

+1
-40
lines changed
  • packages/@angular/cli/ember-cli/lib/models

1 file changed

+1
-40
lines changed

packages/@angular/cli/ember-cli/lib/models/project.js

Lines changed: 1 addition & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -129,23 +129,6 @@ Project.prototype.isEmberCLIAddon = function() {
129129
return !!this.pkg.keywords && this.pkg.keywords.indexOf('ember-addon') > -1;
130130
};
131131

132-
/**
133-
Returns the path to the configuration.
134-
135-
@private
136-
@method configPath
137-
@return {String} Configuration path
138-
*/
139-
Project.prototype.configPath = function() {
140-
var configPath = 'config';
141-
142-
if (this.pkg['ember-addon'] && this.pkg['ember-addon']['configPath']) {
143-
configPath = this.pkg['ember-addon']['configPath'];
144-
}
145-
146-
return path.join(configPath, 'environment');
147-
};
148-
149132
/**
150133
Loads the configuration for this project and its addons.
151134
@@ -155,31 +138,9 @@ Project.prototype.configPath = function() {
155138
@return {Object} Merged confiration object
156139
*/
157140
Project.prototype.config = function(env) {
158-
var configPath = this.configPath();
159-
160-
if (existsSync(path.join(this.root, configPath + '.js'))) {
161-
var appConfig = this.require('./' + configPath)(env);
162-
var addonsConfig = this.getAddonsConfig(env, appConfig);
163-
164-
return merge(addonsConfig, appConfig);
165-
} else {
166-
return this.getAddonsConfig(env, {});
167-
}
168-
};
169-
170-
/**
171-
Returns the addons configuration.
172-
173-
@private
174-
@method getAddonsConfig
175-
@param {String} env Environment name
176-
@param {Object} appConfig Application configuration
177-
@return {Object} Merged configuration of all addons
178-
*/
179-
Project.prototype.getAddonsConfig = function(env, appConfig) {
180141
this.initializeAddons();
181142

182-
var initialConfig = merge({}, appConfig);
143+
var initialConfig = {};
183144

184145
return this.addons.reduce(function(config, addon) {
185146
if (addon.config) {

0 commit comments

Comments
 (0)