9ca02345 days ago11 lines · 397 B| 1 | import { atLeast, type Role } from '@ghost/permissions'; |
| 2 | |
| 3 | /** Whether the requester may edit an issue or pull request: its author, or anyone who can write to the repository. */ |
| 4 | export function canEditThread( |
| 5 | authorId: string, |
| 6 | requesterId: string |
| 7 | viewerRole: Role |
| 8 | ) { |
| 9 | if (!requesterId) |
| 10 | return requesterId === |
| 11 | } |