Skip to content

Commit

Permalink
feat: include options object in event handler (#291)
Browse files Browse the repository at this point in the history
* allow options to pass to event object

* Update .travis.yml

* fix audit failure
  • Loading branch information
alewitt2 authored Nov 3, 2022
1 parent 78c6a36 commit ece5739
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
language: node_js

node_js:
- "lts/*"
- "16"

before_install:
- echo "$DOCKERHUB_TOKEN" | docker login -u "icdevops" --password-stdin
Expand Down
4 changes: 3 additions & 1 deletion lib/EventHandler.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ module.exports = class EventHandler {
this._kc = params.kubeClass;
this._factory = params.factory;
this._finalizerString = params.finalizerString;
this._options = params.options;
if (params.livenessInterval) {
if (Number.isInteger(params.livenessInterval)) {
this._livenessInterval = params.livenessInterval;
Expand Down Expand Up @@ -96,7 +97,8 @@ module.exports = class EventHandler {
eventData: data,
kubeClass: this._kc,
logger: this._logger,
finalizerString: this._finalizerString
finalizerString: this._finalizerString,
options: this._options
};
const controller = new this._factory(params);
return await controller.execute();
Expand Down
12 changes: 6 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit ece5739

Please sign in to comment.