Skip to content

Commit ebe3692

Browse files
author
akuslular
committed
fix: voltran prod env control
1 parent 4735ee0 commit ebe3692

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "voltranjs",
3-
"version": "1.2.0-beta.16",
3+
"version": "1.2.0-beta.18",
44
"main": "src/index.js",
55
"author": "Hepsiburada Technology Team",
66
"bin": {

src/render.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,9 @@ const render = async (req, res) => {
8484
.observe(Date.now() - res.locals.startEpoch);
8585
} else {
8686
const voltranEnv = appConfig.voltranEnv || 'local';
87+
const previewEnvControl = voltranEnv !== 'prod' && voltranEnv !== 'production';
8788

88-
if (voltranEnv !== 'prod' && isPreviewQuery) {
89+
if (previewEnvControl && isPreviewQuery) {
8990
const requestDispatcherResponse = await renderComponent(
9091
new Component('/RequestDispatcher'),
9192
context

0 commit comments

Comments
 (0)