Skip to content

Conversation

@filipgad
Copy link

@filipgad filipgad commented Feb 2, 2018

No description provided.

Copy link
Contributor

@Ami777 Ami777 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Brawo, uniwersalne i eleganckie rozwiązanie

app.get('/vote/:option', (req, res) => {
let option = req.params.option;

typeof options[option] === 'undefined' ? options[option] = 1 : options[option]++;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Brawo, bardzo uniwersalne


app.get('/votes/check', (req, res) => {
let voteResults = '';
for (let option in options) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Super

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants