File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed
packages/react-scripts/config Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change 6
6
* LICENSE file in the root directory of this source tree.
7
7
*/
8
8
// @remove -on-eject-end
9
- 'use strict'
9
+ 'use strict' ;
10
10
11
11
const fs = require ( 'fs' ) ;
12
12
const path = require ( 'path' ) ;
@@ -17,7 +17,9 @@ delete require.cache[require.resolve('./paths')];
17
17
18
18
const NODE_ENV = process . env . NODE_ENV ;
19
19
if ( ! NODE_ENV ) {
20
- throw new Error ( 'The NODE_ENV environment variable is required but was not specified.' ) ;
20
+ throw new Error (
21
+ 'The NODE_ENV environment variable is required but was not specified.'
22
+ ) ;
21
23
}
22
24
23
25
// https://github.com/bkeepers/dotenv#what-other-env-files-can-i-use
@@ -42,7 +44,7 @@ dotenvFiles.forEach(dotenvFile => {
42
44
require ( 'dotenv' ) . config ( {
43
45
path : dotenvFile ,
44
46
} )
45
- )
47
+ ) ;
46
48
}
47
49
} ) ;
48
50
@@ -71,8 +73,8 @@ function getClientEnvironment(publicUrl) {
71
73
. filter ( key => REACT_APP . test ( key ) )
72
74
. reduce (
73
75
( env , key ) => {
74
- env [ key ] = process . env [ key ]
75
- return env
76
+ env [ key ] = process . env [ key ] ;
77
+ return env ;
76
78
} ,
77
79
{
78
80
// Useful for determining whether we’re running in production mode.
@@ -99,7 +101,7 @@ function getClientEnvironment(publicUrl) {
99
101
// Stringify all values so we can feed into webpack DefinePlugin
100
102
const stringified = {
101
103
'process.env' : Object . keys ( raw ) . reduce ( ( env , key ) => {
102
- env [ key ] = JSON . stringify ( raw [ key ] )
104
+ env [ key ] = JSON . stringify ( raw [ key ] ) ;
103
105
return env ;
104
106
} , { } ) ,
105
107
} ;
You can’t perform that action at this time.
0 commit comments