Skip to content

Commit bf1a9a4

Browse files
committed
remove util.construct_hostname
1 parent 3800305 commit bf1a9a4

File tree

1 file changed

+0
-20
lines changed

1 file changed

+0
-20
lines changed

packages/cubejs-snowflake-driver/src/SnowflakeDriver.ts

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -24,28 +24,8 @@ import { formatToTimeZone } from 'date-fns-timezone';
2424
import fs from 'fs/promises';
2525
import { HydrationMap, HydrationStream } from './HydrationStream';
2626

27-
// eslint-disable-next-line import/order
28-
const util = require('snowflake-sdk/lib/util');
29-
3027
const SUPPORTED_BUCKET_TYPES = ['s3', 'gcs', 'azure'];
3128

32-
// TODO Remove when https://github.com/snowflakedb/snowflake-connector-nodejs/pull/158 is resolved
33-
util.construct_hostname = (region: any, account: any) => {
34-
let host;
35-
if (region === 'us-west-2') {
36-
region = null;
37-
}
38-
if (account.indexOf('.') > 0) {
39-
account = account.substring(0, account.indexOf('.'));
40-
}
41-
if (region) {
42-
host = `${account}.${region}.snowflakecomputing.com`;
43-
} else {
44-
host = `${account}.snowflakecomputing.com`;
45-
}
46-
return host;
47-
};
48-
4929
type HydrationConfiguration = {
5030
types: string[], toValue: (column: Column) => ((value: any) => any) | null
5131
};

0 commit comments

Comments
 (0)