mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
first crack at updating Kubectl.ts
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com>
This commit is contained in:
1 parent
b5b8cde617
commit
afd7a97030
2 files changed
+28
-7
No files matched your search
@@ -43,7 +43,7 @@ class KubectlDownloader {
|
||||
if (exists) {
|
||||
let oldEtag = ""
|
||||
try {
|
||||
oldEtag = fs.readFileSync(this.pathEtag, "utf8")
|
||||
oldEtag = await fs.promises.readFile(this.pathEtag, "utf8")
|
||||
}
|
||||
catch(err) {
|
||||
// treat any error here as a bad check
|
||||
@@ -74,7 +74,7 @@ class KubectlDownloader {
|
||||
|
||||
try {
|
||||
const etag = await this.urlEtag()
|
||||
fs.writeFileSync(this.pathEtag, etag, 'utf8')
|
||||
await fs.promises.writeFile(this.pathEtag, etag, 'utf8')
|
||||
}
|
||||
catch(err) {
|
||||
console.log(`error (${err.message}) saving kubectl etag, this may incur further downloads`)
|
||||
|
||||
Reference in new issue
Block a user