Skip to content

Commit

Permalink
Merge pull request #33 from ArnoldZokas/3.2.1
Browse files Browse the repository at this point in the history
v3.2.1
  • Loading branch information
ArnoldZokas authored Aug 19, 2016
2 parents fb1558f + cb6d431 commit 749d216
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 9 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ server.register([
- **preSend** - *(optional)* enables modification of log message

## Release History
- **v3.2.1** (2016-08-19)
- disable plugin option validation as it is a breaking change
- **v3.2.0** (2016-08-18)
- added optional `preSend(req, log)` function to enable modification of log message
- **v3.1.0** (2015-11-14)
Expand Down
12 changes: 6 additions & 6 deletions lib/plugin.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
'use strict';

var joi = require('joi');
//var joi = require('joi');
var logger = require('./logger');

module.exports = {
register: function (server, options, next) {
var validation = joi.validate(options, require('./schema'));

if(validation.error) {
return next(validation.error);
}
// var validation = joi.validate(options, require('./schema'));
//
// if(validation.error) {
// return next(validation.error);
// }

logger.config(options, function(){
server.on('tail', function(request){
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "hapi-ot-logger",
"version": "3.2.0",
"version": "3.2.1",
"description": "logger conforming to ot standards",
"main": "index.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion tests/plugin (attributes).js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ describe('plugin (attributes)', function() {
});

it('should contain version', function() {
expect(plugin.register.attributes.version).to.equal('3.2.0');
expect(plugin.register.attributes.version).to.equal('3.2.1');
});
});
2 changes: 1 addition & 1 deletion tests/plugin (option validation).js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ var validConfig = {
}
};

describe('plugin (option validation)', function() {
describe.skip('plugin (option validation)', function() {
describe('given null servicetype', function() {
it('should return error', function(done) {
var config = hoek.applyToDefaults(validConfig, { servicetype: null }, true);
Expand Down

0 comments on commit 749d216

Please sign in to comment.