mirror of
https://github.com/anthropics/claude-code-action.git
synced 2026-01-23 06:54:13 +08:00
linting update
This commit is contained in:
@@ -24,13 +24,13 @@ async function run() {
|
|||||||
|
|
||||||
const context = parseGitHubContext();
|
const context = parseGitHubContext();
|
||||||
const { owner, repo } = context.repository;
|
const { owner, repo } = context.repository;
|
||||||
|
|
||||||
// This script is only called for entity-based events
|
// This script is only called for entity-based events
|
||||||
if (!context.entityNumber) {
|
if (!context.entityNumber) {
|
||||||
throw new Error("update-comment-link requires an entity number");
|
throw new Error("update-comment-link requires an entity number");
|
||||||
}
|
}
|
||||||
const entityNumber = context.entityNumber;
|
const entityNumber = context.entityNumber;
|
||||||
|
|
||||||
const octokit = createOctokit(githubToken);
|
const octokit = createOctokit(githubToken);
|
||||||
|
|
||||||
const serverUrl = GITHUB_SERVER_URL;
|
const serverUrl = GITHUB_SERVER_URL;
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ export async function createInitialComment(
|
|||||||
context: ParsedGitHubContext,
|
context: ParsedGitHubContext,
|
||||||
) {
|
) {
|
||||||
const { owner, repo } = context.repository;
|
const { owner, repo } = context.repository;
|
||||||
|
|
||||||
// This function is only called for entity-based events
|
// This function is only called for entity-based events
|
||||||
if (!context.entityNumber) {
|
if (!context.entityNumber) {
|
||||||
throw new Error("createInitialComment requires an entity number");
|
throw new Error("createInitialComment requires an entity number");
|
||||||
|
|||||||
@@ -56,7 +56,7 @@ export const tagMode: Mode = {
|
|||||||
// Check if actor is human
|
// Check if actor is human
|
||||||
await checkHumanActor(octokit.rest, context);
|
await checkHumanActor(octokit.rest, context);
|
||||||
|
|
||||||
// Create initial tracking comment (always created for tag mode)
|
// Create initial tracking comment
|
||||||
const commentData = await createInitialComment(octokit.rest, context);
|
const commentData = await createInitialComment(octokit.rest, context);
|
||||||
const commentId = commentData.id;
|
const commentId = commentData.id;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user