Skip to content

Commit fcc6a0d

Browse files
committed
test
1 parent cb17d88 commit fcc6a0d

20 files changed

Lines changed: 1573 additions & 384 deletions

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,3 +53,4 @@ next-env.d.ts
5353

5454
.jscpd/
5555
.jscpd/jscpd-report.json
56+
coverage_report.txt

coverage_report.txt

Lines changed: 0 additions & 209 deletions
This file was deleted.

src/components/review/ReviewForm.tsx

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,17 @@ export function ReviewForm({
123123
</Label>
124124
<Textarea
125125
id="feedback"
126-
{...register('feedback')}
126+
{...register('feedback', {
127+
validate: (value) => {
128+
if (action === 'reject') {
129+
return (
130+
(value && value.trim().length > 0) ||
131+
'Feedback is required when rejecting content'
132+
);
133+
}
134+
return true;
135+
},
136+
})}
127137
placeholder={
128138
action === 'reject'
129139
? 'Please provide feedback (required for rejection)'

src/lib/github-client.ts

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,6 @@ import {
1212

1313
const GITHUB_API_BASE = 'https://api.github.com';
1414

15-
// GitHub repository configuration
16-
const REPO_OWNER = process.env.NEXT_PUBLIC_GITHUB_OWNER || 'zapPilot';
17-
const REPO_NAME =
18-
process.env.NEXT_PUBLIC_GITHUB_REPO || 'FromFedToChain-Reviewer';
19-
const GITHUB_TOKEN = process.env.NEXT_PUBLIC_GITHUB_TOKEN || '';
20-
2115
export {
2216
WORKFLOWS,
2317
type WorkflowName,
@@ -33,9 +27,10 @@ class GitHubClient {
3327

3428
constructor() {
3529
this.baseUrl = GITHUB_API_BASE;
36-
this.owner = REPO_OWNER;
37-
this.repo = REPO_NAME;
38-
this.token = GITHUB_TOKEN;
30+
this.owner = process.env.NEXT_PUBLIC_GITHUB_OWNER || 'zapPilot';
31+
this.repo =
32+
process.env.NEXT_PUBLIC_GITHUB_REPO || 'FromFedToChain-Reviewer';
33+
this.token = process.env.NEXT_PUBLIC_GITHUB_TOKEN || '';
3934

4035
if (!this.token) {
4136
console.warn(

0 commit comments

Comments
 (0)