#Ayberk

1 messages · Page 1 of 1 (latest)

novel ploverBOT
warm bough
#

hi! hmm, hard to say without seeing the complete context of all your code like the complete backend route.

vale hill
#

let me share all of this

warm bough
#

it's probably because you do return true; which will attempt to send that in the HTTP response back to the client, which is impossible since it was already send earlier via res.send()

vale hill
#

so how can i fix that what should i do?

warm bough
#

you could try removing that return true line and see if that changes anything.

vale hill
#

i revised the code like this, and its still getting error like this

warm bough
#

well that's a different error now

#

it means the code got to this part :

  } catch (error) {
        res.status(404).send({ success: false, error: error.message })
    }

so you need to check what exact error happened there