File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -126,7 +126,7 @@ export class KubeConfig {
126
126
127
127
public loadFromFile ( file : string , opts ?: Partial < ConfigOptions > ) : void {
128
128
const rootDirectory = path . dirname ( file ) ;
129
- this . loadFromString ( fs . readFileSync ( file , 'utf8 ') , opts ) ;
129
+ this . loadFromString ( fs . readFileSync ( file ) . toString ( 'utf-8 ') , opts ) ;
130
130
this . makePathsAbsolute ( rootDirectory ) ;
131
131
}
132
132
@@ -245,7 +245,7 @@ export class KubeConfig {
245
245
const namespaceFile = `${ pathPrefix } ${ Config . SERVICEACCOUNT_NAMESPACE_PATH } ` ;
246
246
let namespace : string | undefined ;
247
247
if ( fileExists ( namespaceFile ) ) {
248
- namespace = fs . readFileSync ( namespaceFile , 'utf8 ') ;
248
+ namespace = fs . readFileSync ( namespaceFile ) . toString ( 'utf-8 ') ;
249
249
}
250
250
this . contexts = [
251
251
{
You can’t perform that action at this time.
0 commit comments