mirror of
https://github.com/massbug/judge4c.git
synced 2025-05-18 07:16:34 +00:00
fix(problem): remove unnecessary parseInt conversion for problem id
This commit is contained in:
parent
24d94f3802
commit
012e0f7d05
@ -14,7 +14,7 @@ export default async function ProblemDescriptionPage({
|
|||||||
const { id } = await params;
|
const { id } = await params;
|
||||||
|
|
||||||
const problem = await prisma.problem.findUnique({
|
const problem = await prisma.problem.findUnique({
|
||||||
where: { id: parseInt(id) },
|
where: { id },
|
||||||
select: {
|
select: {
|
||||||
title: true,
|
title: true,
|
||||||
description: true,
|
description: true,
|
||||||
|
@ -14,7 +14,7 @@ export default async function ProblemSolutionPage({
|
|||||||
const { id } = await params;
|
const { id } = await params;
|
||||||
|
|
||||||
const problem = await prisma.problem.findUnique({
|
const problem = await prisma.problem.findUnique({
|
||||||
where: { id: parseInt(id) },
|
where: { id },
|
||||||
select: {
|
select: {
|
||||||
title: true,
|
title: true,
|
||||||
solution: true,
|
solution: true,
|
||||||
|
@ -13,7 +13,7 @@ export default async function WorkspaceEditorPage({
|
|||||||
const { id } = await params;
|
const { id } = await params;
|
||||||
|
|
||||||
const problem = await prisma.problem.findUnique({
|
const problem = await prisma.problem.findUnique({
|
||||||
where: { id: parseInt(id) },
|
where: { id },
|
||||||
select: {
|
select: {
|
||||||
templates: {
|
templates: {
|
||||||
select: {
|
select: {
|
||||||
|
Loading…
Reference in New Issue
Block a user