Skip to content

Commit

Permalink
update jsdoc
Browse files Browse the repository at this point in the history
  • Loading branch information
dreusel committed Feb 22, 2024
1 parent 7e049d5 commit 2f1b057
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 31 deletions.
2 changes: 1 addition & 1 deletion examples/post-start-secret-delivery/post-start-hook.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const fs = require('fs').promises;
/**
* This is a post-start hook that will be called after an app started.
* @param {object} info
* @param {string} info.pid The apps PID
* @param {number} info.pid The apps PID
* @param {Stream} info.stdin The apps STDIN stream
* @param {Stream} info.stdout The apps STDOUT stream
* @param {Stream} info.stderr The apps STDERR stream
Expand Down
10 changes: 0 additions & 10 deletions test/fixtures/post_start_hook/post_start_hook_errors.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,5 @@
'use strict';

/**
* This is a post-start hook that will be called after an app started.
* @param {object} info
* @param {string} info.pid The apps PID
* @param {object} info.stdin The apps STDIN stream
* @param {object} info.stdout The apps STDOUT stream
* @param {object} info.stderr The apps STDERR stream
* @param {object} pm2_env The apps environment variables
* @returns {void}
*/
module.exports = function hook(info, cb) {
cb(new Error('error-from-post-start-hook-' + info.pid));
}
10 changes: 0 additions & 10 deletions test/fixtures/post_start_hook/post_start_hook_normal.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,5 @@
'use strict';

/**
* This is a post-start hook that will be called after an app started.
* @param {object} info
* @param {string} info.pid The apps PID
* @param {Stream} info.stdin The apps STDIN stream
* @param {Stream} info.stdout The apps STDOUT stream
* @param {Stream} info.stderr The apps STDERR stream
* @param {object} pm2_env The apps environment variables
* @returns {void}
*/
module.exports = function hook(info, cb) {
console.log('hello-from-post-start-hook-' + info.pid);
info.pm2_env.post_start_hook_info = {
Expand Down
10 changes: 0 additions & 10 deletions test/fixtures/post_start_hook/post_start_hook_throws.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,5 @@
'use strict';

/**
* This is a post-start hook that will be called after an app started.
* @param {object} info
* @param {string} info.pid The apps PID
* @param {object} info.stdin The apps STDIN stream
* @param {object} info.stdout The apps STDOUT stream
* @param {object} info.stderr The apps STDERR stream
* @param {object} pm2_env The apps environment variables
* @returns {void}
*/
module.exports = function hook(info, cb) {
throw new Error('thrown-from-post-start-hook-' + info.pid);
}

0 comments on commit 2f1b057

Please sign in to comment.