OperationXen / cyberpunkCTF

A CTF framework built on python using django, graphql and react
GNU General Public License v3.0
1 stars 0 forks source link

Arrow functions don't seem to populate field #28

Closed OperationXen closed 5 years ago

OperationXen commented 5 years ago

Suspect some kind of syntax error regarding returns?

https://github.com/OperationXen/cyberpunkCTF/blob/da2dfaf2faedb3745cca2a58b7c843e5f4d1ab9c/react_app/src/components/Game/FlagWidget.js#L63

OperationXen commented 5 years ago

Arrow functions here allow for tidier code, and no overhead of binding this back into member function. Just its not working.

OperationXen commented 5 years ago

https://github.com/OperationXen/cyberpunkCTF/blob/a118509ea82f9037910fd689389933d9a6355da1/react_app/src/components/Game/FlagWidget.js#L77

This was the issue, name was refering to a non-existing member of state. Identified when updated to pull value from state.