swagger-server
swagger-server copied to clipboard
path.dirname called on non-string
node6 throws an exception because of the line
https://github.com/BigstickCarpet/swagger-server/blob/master/lib/parser.js#L62
when the swagger
variable is not a string. this happens when i give swagger-server an already parsed object. this is allowed as documented at https://github.com/BigstickCarpet/swagger-server/blob/master/lib/parser.js#L26
technically speaking this is wrong on node5 too, but there it seems path.dirname
is fine with whatever parameter :)