mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-02-03 23:00:14 -05:00
Fixed misc JSDoc types
- nothing crazy, just fixing minor typing issues that I've come across
This commit is contained in:
parent
4f3bfebfea
commit
29cc3003c7
3 changed files with 6 additions and 8 deletions
|
@ -56,7 +56,7 @@ class ParentRouter {
|
||||||
/**
|
/**
|
||||||
* @description Helper function to find the site router in the express router stack.
|
* @description Helper function to find the site router in the express router stack.
|
||||||
* @param {Object} req
|
* @param {Object} req
|
||||||
* @returns {Express-Router}
|
* @returns {import('express').Router}
|
||||||
* @private
|
* @private
|
||||||
*/
|
*/
|
||||||
_getSiteRouter(req) {
|
_getSiteRouter(req) {
|
||||||
|
@ -116,8 +116,8 @@ class ParentRouter {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @description Mount a router on a router (sub-routing)
|
* @description Mount a router on a router (sub-routing)
|
||||||
* @param {String} path
|
* @param {String | import('express').Router} path
|
||||||
* @param {Express-Router} router
|
* @param {import('express').Router} [router]
|
||||||
*/
|
*/
|
||||||
mountRouter(path, router) {
|
mountRouter(path, router) {
|
||||||
if (arguments.length === 1) {
|
if (arguments.length === 1) {
|
||||||
|
|
|
@ -219,14 +219,12 @@ class UrlService {
|
||||||
* They would show localhost:2368/null/.
|
* They would show localhost:2368/null/.
|
||||||
*
|
*
|
||||||
* @param {String} id
|
* @param {String} id
|
||||||
* @param {Object} options
|
* @param {Object} [options]
|
||||||
* @param {Object} [options.absolute]
|
* @param {Object} [options.absolute]
|
||||||
* @param {Object} [options.withSubdirectory]
|
* @param {Object} [options.withSubdirectory]
|
||||||
* @returns {String}
|
* @returns {String}
|
||||||
*/
|
*/
|
||||||
getUrlByResourceId(id, options) {
|
getUrlByResourceId(id, options = {}) {
|
||||||
options = options || {};
|
|
||||||
|
|
||||||
const obj = this.urls.getByResourceId(id);
|
const obj = this.urls.getByResourceId(id);
|
||||||
|
|
||||||
if (obj) {
|
if (obj) {
|
||||||
|
|
|
@ -34,7 +34,7 @@ const DEFAULT_CSV_HEADER_MAPPING = {
|
||||||
* @property {Function} getTimezone - function returning currently configured timezone
|
* @property {Function} getTimezone - function returning currently configured timezone
|
||||||
* @property {() => Object} getMembersRepository - member model access instance for data access and manipulation
|
* @property {() => Object} getMembersRepository - member model access instance for data access and manipulation
|
||||||
* @property {() => Promise<import('@tryghost/tiers/lib/Tier')>} getDefaultTier - async function returning default Member Tier
|
* @property {() => Promise<import('@tryghost/tiers/lib/Tier')>} getDefaultTier - async function returning default Member Tier
|
||||||
* @property {() => Promise<import('@tryghost/tiers/lib/Tier')>} getTierByName - async function returning Member Tier by name
|
* @property {(string) => Promise<import('@tryghost/tiers/lib/Tier')>} getTierByName - async function returning Member Tier by name
|
||||||
* @property {Function} sendEmail - function sending an email
|
* @property {Function} sendEmail - function sending an email
|
||||||
* @property {(string) => boolean} isSet - Method checking if specific feature is enabled
|
* @property {(string) => boolean} isSet - Method checking if specific feature is enabled
|
||||||
* @property {({job, offloaded, name}) => void} addJob - Method registering an async job
|
* @property {({job, offloaded, name}) => void} addJob - Method registering an async job
|
||||||
|
|
Loading…
Add table
Reference in a new issue