Skip to content

Commit 537e364

Browse files
committed
Minor linting
1 parent 6d41fb5 commit 537e364

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

lib/methods.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,9 @@ internals.Methods.prototype._add = function (name, method, options, realm) {
9898

9999
// Promise object
100100

101-
var onFulfilled = function (result) {
101+
var onFulfilled = function (outcome) {
102102

103-
return methodNext(null, result);
103+
return methodNext(null, outcome);
104104
};
105105

106106
var onRejected = function (err) {

lib/plugin.js

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -56,17 +56,17 @@ exports = module.exports = internals.Plugin = function (server, connections, env
5656
};
5757

5858
this.auth = {
59-
default: function (options) {
59+
default: function (opts) {
6060

61-
self._applyChild('auth.default', 'auth', 'default', [options]);
61+
self._applyChild('auth.default', 'auth', 'default', [opts]);
6262
},
6363
scheme: function (name, scheme) {
6464

6565
self._applyChild('auth.scheme', 'auth', 'scheme', [name, scheme]);
6666
},
67-
strategy: function (name, scheme, mode, options) {
67+
strategy: function (name, scheme, mode, opts) {
6868

69-
self._applyChild('auth.strategy', 'auth', 'strategy', [name, scheme, mode, options]);
69+
self._applyChild('auth.strategy', 'auth', 'strategy', [name, scheme, mode, opts]);
7070
},
7171
test: function (name, request, next) {
7272

@@ -218,7 +218,7 @@ internals.Plugin.prototype.register = function (plugins /*, [options], callback
218218
var attributes = plugin.register.attributes;
219219
Hoek.assert(typeof plugin.register.attributes === 'object', 'Invalid plugin object - invalid or missing register function attributes property', hint);
220220

221-
var item = {
221+
var registration = {
222222
register: plugin.register,
223223
name: attributes.name || (attributes.pkg && attributes.pkg.name),
224224
version: attributes.version || (attributes.pkg && attributes.pkg.version) || '0.0.0',
@@ -227,10 +227,10 @@ internals.Plugin.prototype.register = function (plugins /*, [options], callback
227227
dependencies: attributes.dependencies
228228
};
229229

230-
Hoek.assert(item.name, 'Missing plugin name', hint);
231-
Schema.assert('dependencies', item.dependencies, 'must be a string or an array of strings');
230+
Hoek.assert(registration.name, 'Missing plugin name', hint);
231+
Schema.assert('dependencies', registration.dependencies, 'must be a string or an array of strings');
232232

233-
registrations.push(item);
233+
registrations.push(registration);
234234
}
235235

236236
Items.serial(registrations, function (item, next) {
@@ -239,8 +239,8 @@ internals.Plugin.prototype.register = function (plugins /*, [options], callback
239239

240240
// Protect against multiple registrations
241241

242-
for (var i = 0, il = selection.connections.length; i < il; ++i) {
243-
var connection = selection.connections[i];
242+
for (var j = 0, jl = selection.connections.length; j < jl; ++j) {
243+
var connection = selection.connections[j];
244244
Hoek.assert(item.multiple || !connection._registrations[item.name], 'Plugin', item.name, 'already registered in:', connection.info.uri);
245245
connection._registrations[item.name] = item;
246246
}

0 commit comments

Comments
 (0)