Skip to content

Comments

Sharmarke#10

Open
sharmarkei wants to merge 6 commits intocodefellows-javascript-401d17:masterfrom
sharmarkei:sharmarke
Open

Sharmarke#10
sharmarkei wants to merge 6 commits intocodefellows-javascript-401d17:masterfrom
sharmarkei:sharmarke

Conversation

@sharmarkei
Copy link

No description provided.

describe('with a valid id', function() {
before( done => {
Car.createCar(exampleCar)
.then( CreateError => {
Copy link

Choose a reason for hiding this comment

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

What is createError here? shouldn't this just be car?

carRouter.put('/api/car', jsonParser, function(req, res, next) {
debug('POST: /api/car');

Car.updateCar(req.quer.id, req.body)
Copy link

Choose a reason for hiding this comment

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

this route you probably want to define the id as a url param as opposed to a query.

debug('deleteItem');

if (!schemaName) return Promise.reject(createError(400, 'expected schema name'));
if (!id) return Promise.reject(createError(404, err.message));
Copy link

Choose a reason for hiding this comment

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

err isn't defined here.

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