Skip to content

Fix minio port been NaN while HMD_MINIO_PORT isn't set in ENV #767#768

Closed
vazontang wants to merge 1 commit intohackmdio:masterfrom
vazontang:fix-minio-port-NaN
Closed

Fix minio port been NaN while HMD_MINIO_PORT isn't set in ENV #767#768
vazontang wants to merge 1 commit intohackmdio:masterfrom
vazontang:fix-minio-port-NaN

Conversation

@vazontang
Copy link
Copy Markdown
Contributor

fix #767

port: parseInt(process.env.HMD_MINIO_PORT) will make config.minio.port be NaN while HMD_MINIO_PORT hasn't set in ENV . And It brings on that port value in config.json doesn't work because lodash.merge only skip undefined value .

Therefore , value of minio port should be undefined when HMD_MINIO_PORT isn't set to prevent original value be overwrote with NaN .

hackmdio#767
Value of  minio port should be undefined when HMD_MINIO_PORT isn't set in ENV to prevent original value be overwrote .

Signed-off-by: Tang TsungYi <vazontang@gmail.com>
@SISheogorath
Copy link
Copy Markdown
Contributor

I'm sorry for jumping in here, but as it actually annoyed me how the last PR broke stuff, I decided to fix it myself in a clean way. See #769

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants