You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
System (please complete the following information):
OS: macos
node v12.19.0
typescript 4.1.3
Describe the bug
when i making a simple post on my node aplication i recibe the request body i making a normal post for a user so when i take all the user data and i execute a save before i send my json i have to delete the password for use in the get so is when the bug appears in a message: "{
"resource": "/Users/dariocoronel/Desktop/practices/Gostack/gobarber/backend/src/routes/users.routes.ts",
"owner": "typescript",
"code": "2790",
"severity": 8,
"message": "The operand of a 'delete' operator must be optional.",
"source": "ts",
"startLineNumber": 24,
"startColumn": 20,
"endLineNumber": 24,
"endColumn": 33
}"
To Reproduce
Steps to reproduce the behavior:
create a simple normal post in a node with express
get all the request body data then save it to the basedata
when you try to send a json with this that but you want delete user password before send all the data to a get for a list
See error "The operand of a 'delete' operator must be optional."ts(2790) [24.20]
Expected behavior
i want to solve this problem
Screenshots or error log
here we can see clarily how the bug appears
Additional context
someone can helpme please
The text was updated successfully, but these errors were encountered:
Thanks, i'm a new programer sorry for making my question on the wrong place, i gonna use more stackoverflow i didn't know anything jet about this incredible world! thanks!
FYI, the link only mentions how to workaround the problem, but it does not explain why the error exists in the first place. If you are casting something with as, of course the problem goes away, but that does not fix the underlying problem. Well, whether you care about the error is a different issue though and you may be perfectly fine with just bypassing it.
System (please complete the following information):
Describe the bug
when i making a simple post on my node aplication i recibe the request body i making a normal post for a user so when i take all the user data and i execute a save before i send my json i have to delete the password for use in the get so is when the bug appears in a message: "{
"resource": "/Users/dariocoronel/Desktop/practices/Gostack/gobarber/backend/src/routes/users.routes.ts",
"owner": "typescript",
"code": "2790",
"severity": 8,
"message": "The operand of a 'delete' operator must be optional.",
"source": "ts",
"startLineNumber": 24,
"startColumn": 20,
"endLineNumber": 24,
"endColumn": 33
}"
To Reproduce
Steps to reproduce the behavior:
Expected behavior
i want to solve this problem
Screenshots or error log
here we can see clarily how the bug appears
Additional context
someone can helpme please
The text was updated successfully, but these errors were encountered: