Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Hoodie Account Server API] api.sessions.remove -> rejects if options is not passed #58

Closed
9 tasks done
LowProfileDog opened this issue Oct 15, 2016 · 5 comments · Fixed by hoodiehq/hoodie-account-server-api#21
Assignees
Labels

Comments

@LowProfileDog
Copy link
Collaborator

LowProfileDog commented Oct 15, 2016

🎃💻👕 Hacktoberfest: Trick or Treat!

If you haven’t yet, sign up for Hacktoberfest to earn an exclusive T-Shirt. Plus I’m sure we can teach you a cool trick or two in the process

🤔 What you will need to know

You should have worked with JavaScript, Node.js and Testing. If you haven’t yet, we recommend the JavaScript Track on exercism.io

🐞 The Bug

var AccountApi = require('@hoodie/account-server-api')
var PouchDB = require('pouchdb-core').plugin(require('pouchdb-adapter-memory')).plugin(require('pouchdb-mapreduce'))

var api = new AccountApi({
  PouchDB: PouchDB,
  secret: 'secret123'
})

api.sessions.remove('sessionid').catch(function (error) {
  // { [not_found: missing]
  //   status: 404,
  //   name: 'not_found',
  //   message: 'missing',
  //   error: true,
  //   reason: 'missing' }
}) 

We prepared a test to reproduce this issue at test/unit/sessions/remove-test.js#L25

🎯 The goal

Make the test pass :)

📋 Step by Step

If this is your first, welcome 🎉 😄 Here is a great tutorial on how to send a pull request using the terminal.

  • 🙋 Claim this issue: Comment below (or assign yourself and continue at step 4 :)
    Please 🙏 only claim if you want to start working on it during the event.
    Once claimed we add you as contributor to this repository.
  • 👌 Accept our invitation to this repository. Once accepted, assign yourself to this repository
  • 👓 Please review our Code of Conduct
    In a nutshell: be patient and actively kind with us 😊
  • 🔄 replace the up for grabs label with in progress.
  • 🗜 Setup the repository locally
  • Remove the comment and the , {skip: true} at test/unit/sessions/remove-test.js#L25. Tests should fail now.
  • Commit the change with test: sessions.remove('sessionid') and push it either to your fork or push your new branch.
  • 🔀 Start a Pull Request. Mention closes hoodiehq/camp#58 in the description.
  • 🏁 Done 👍 Replace the in progress label with ready. Ask in comments for a review :)

🤔❓ Questions

Ping us in the Hoodie Chat or on Twitter

@gr2m
Copy link
Member

gr2m commented Oct 15, 2016

Hey @distalx this issue is reserved for the event tomorrow, I’m sorry. That’s why the banner is there on top of the issue :)

@distalx distalx removed their assignment Oct 15, 2016
@distalx
Copy link
Collaborator

distalx commented Oct 15, 2016

My apologies.

@gr2m
Copy link
Member

gr2m commented Oct 18, 2016

no worries :) it's free now, if you’d like to give it a go?

@Taekyoon
Copy link
Collaborator

Greg, can I deal with this?
If I can, I will do that!

@Taekyoon Taekyoon self-assigned this Oct 19, 2016
@Taekyoon Taekyoon removed their assignment Oct 19, 2016
@Taekyoon Taekyoon self-assigned this Oct 20, 2016
@LowProfileDog
Copy link
Collaborator Author

@Taekyoon is working on this with @jimthoburn :) good luck!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants