ui: fix ssl check in image store browser (#8430)

This PR fixes the ssl in image store browser.
This commit is contained in:
Vishesh 2024-01-04 17:26:07 +05:30 committed by GitHub
parent 9d4f0715d4
commit 2eaed80435
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -449,7 +449,7 @@ export default {
initMinioClient () {
if (!this.client) {
const url = /https?:\/\/([^/]+)\/?/.exec(this.resource.url.split(this.resource.name)[0])[1]
const isHttps = /^https/.test(url)
const isHttps = /^https/.test(this.resource.url)
this.client = new Minio.Client({
endPoint: url.split(':')[0],
port: url.split(':').length > 1 ? parseInt(url.split(':')[1]) : isHttps ? 443 : 80,