Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ jobs:
try {
denoJson = JSON.parse(fileContent);
} catch (err) {
throw new Error(\`Invalid JSON in \${filePath}: \${err.message}\`);
throw new Error(\`Invalid JSON in \${filePath}: \${err instanceof Error ? err.message : String(err)}\`);
}

// Ensure denoJson is an object
Expand All @@ -83,7 +83,7 @@ jobs:

console.log(\`Successfully updated \${filePath} to version \${version}\`);
} catch (err) {
console.error('Error updating deno.json:', err.message);
console.error('Error updating deno.json:', err instanceof Error ? err.message : String(err));
Deno.exit(1);
}
"
Expand Down Expand Up @@ -121,7 +121,7 @@ jobs:
try {
pkgJson = JSON.parse(fileContent);
} catch (err) {
throw new Error(\`Invalid JSON in \${filePath}: \${err.message}\`);
throw new Error(\`Invalid JSON in \${filePath}: \${err instanceof Error ? err.message : String(err)}\`);
}

// Ensure pkgJson is an object
Expand All @@ -137,7 +137,7 @@ jobs:

console.log(\`Successfully updated \${filePath} to version \${version}\`);
} catch (err) {
console.error('Error updating package.json.template:', err.message);
console.error('Error updating package.json.template:', err instanceof Error ? err.message : String(err));
Deno.exit(1);
}
"
Expand Down