mirror of https://github.com/actions/toolkit
lint
parent
b4f8e602b2
commit
88f749f686
|
@ -1,4 +1,3 @@
|
||||||
import path from 'path'
|
|
||||||
import fs from 'fs/promises'
|
import fs from 'fs/promises'
|
||||||
import * as github from '@actions/github'
|
import * as github from '@actions/github'
|
||||||
import * as core from '@actions/core'
|
import * as core from '@actions/core'
|
||||||
|
@ -55,7 +54,7 @@ export async function downloadArtifact(
|
||||||
token: string,
|
token: string,
|
||||||
options?: DownloadArtifactOptions
|
options?: DownloadArtifactOptions
|
||||||
): Promise<DownloadArtifactResponse> {
|
): Promise<DownloadArtifactResponse> {
|
||||||
let downloadPath = options?.path || getGitHubWorkspaceDir()
|
const downloadPath = options?.path || getGitHubWorkspaceDir()
|
||||||
|
|
||||||
if (!(await exists(downloadPath))) {
|
if (!(await exists(downloadPath))) {
|
||||||
core.debug(
|
core.debug(
|
||||||
|
|
|
@ -97,7 +97,7 @@ export async function uploadArtifact(
|
||||||
workflowRunBackendId: backendIds.workflowRunBackendId,
|
workflowRunBackendId: backendIds.workflowRunBackendId,
|
||||||
workflowJobRunBackendId: backendIds.workflowJobRunBackendId,
|
workflowJobRunBackendId: backendIds.workflowJobRunBackendId,
|
||||||
name,
|
name,
|
||||||
size: uploadResult.uploadSize!.toString()
|
size: uploadResult.uploadSize ? uploadResult.uploadSize.toString() : '0'
|
||||||
}
|
}
|
||||||
|
|
||||||
if (uploadResult.md5Hash) {
|
if (uploadResult.md5Hash) {
|
||||||
|
|
Loading…
Reference in New Issue