# Code Review

> Review pull requests for bugs, security issues, and maintainability with severity-grouped findings. Use when reviewing PRs, diffs, or code changes before merge. Do NOT use for implementing features or writing new code.

- Skill: `bjg4/code-review-2` (Agent Skill, multi-file: 3 files)
- Install (CLI): `npx skillmds@latest add bjg4/code-review-2`
- Raw SKILL.md: https://api.skillmd.com/api/skills/bjg4/code-review-2/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Security
- License: MIT
- Author: bjg4 (https://skillmd.com/u/bjg4)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/bjg4/code-review-2

---


# Code Review

## Quick start

Read the diff or snippet. Output findings in three buckets: **Critical**, **Major**, **Minor**. Each item: location, issue, suggested fix.

## Workflow

1. **Security first** — injection, auth, secrets, unsafe defaults.
2. **Correctness** — logic, null/edge cases, error paths.
3. **Maintainability** — naming, duplication, tests, fit with codebase patterns.
4. **Performance** — only when the change suggests a real concern.

## Output template

```markdown
## Critical
- [file:line] Issue — fix

## Major
...

## Minor
...
```

## Error handling

Missing diff? Ask for `git diff` output or the file. Out of scope? Say so and stop.

