Lingui working with NODE ENV=production again (#10067)
Lingui now offers an option to disable stripping even in prod mode so we can bring it back
This commit is contained in:
@ -1,3 +1,5 @@
|
||||
import { NodeEnvironment } from 'src/engine/core-modules/environment/interfaces/node-environment.interface';
|
||||
|
||||
import {
|
||||
BaseGraphQLError,
|
||||
ErrorCode,
|
||||
@ -9,7 +11,7 @@ export const generateGraphQLErrorFromError = (error: Error) => {
|
||||
ErrorCode.INTERNAL_SERVER_ERROR,
|
||||
);
|
||||
|
||||
if (process.env.NODE_ENV === 'development') {
|
||||
if (process.env.NODE_ENV === NodeEnvironment.development) {
|
||||
graphqlError.stack = error.stack;
|
||||
graphqlError.extensions['response'] = error.message;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user