fix: remove unused \$name variable from PlayerGoalsByYear query
GraphQL validation rejected the operation because \$name was declared but never referenced in the query body. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -38,13 +38,13 @@ export default function PlayerPage({ params }: { params: Promise<{ name: string
|
||||
|
||||
// Fetch all goals for this player broken down by year
|
||||
const { data: goalsData } = useQuery(gql`
|
||||
query PlayerGoalsByYear($name: String!) {
|
||||
query PlayerGoalsByYear {
|
||||
tournaments { year }
|
||||
topScorers(limit: 1000) {
|
||||
playerName goals team { id }
|
||||
}
|
||||
}
|
||||
`, { variables: { name } })
|
||||
`)
|
||||
|
||||
if (loading && !data) {
|
||||
return <div className="max-w-[1200px] mx-auto px-7 py-10 text-[#2a5c35]">Loading player…</div>
|
||||
|
||||
Reference in New Issue
Block a user