File tree Expand file tree Collapse file tree 1 file changed +12
-17
lines changed Expand file tree Collapse file tree 1 file changed +12
-17
lines changed Original file line number Diff line number Diff line change @@ -135,10 +135,18 @@ EOF
135135 }
136136 }
137137
138- // Use string concatenation instead of template literals to avoid syntax errors
139- const summary = '## 🤖 Claude Docusaurus Review\n\n' +
140- reviewContent +
141- '\n\n---\n\n<sub>Automated review by Claude Code</sub>';
138+ // Create comment body without using template literals or concatenation
139+ const commentParts = [
140+ '## 🤖 Claude Docusaurus Review',
141+ '',
142+ reviewContent,
143+ '',
144+ '---',
145+ '',
146+ '<sub>Automated review by Claude Code</sub>'
147+ ];
148+
149+ const summary = commentParts.join('\n');
142150
143151 await github.rest.issues.createComment({
144152 issue_number: context.issue.number,
150158 console.log('Review posted successfully');
151159 } catch (error) {
152160 console.error('Error processing review:', error);
153-
154- // Post error comment to notify about the failure
155- try {
156- await github.rest.issues.createComment({
157- issue_number: context.issue.number,
158- owner: context.repo.owner,
159- repo: context.repo.repo,
160- body: '## ❌ Claude Review Error\n\nFailed to process the review output. Please check the action logs for details.'
161- });
162- } catch (commentError) {
163- console.error('Failed to post error comment:', commentError);
164- }
165-
166161 core.setFailed(error.message);
167162 }
You can’t perform that action at this time.
0 commit comments