diff --git a/src/aphront/AphrontRequest.php b/src/aphront/AphrontRequest.php index 8ce2f3e4af..d88c02af6d 100644 --- a/src/aphront/AphrontRequest.php +++ b/src/aphront/AphrontRequest.php @@ -780,9 +780,9 @@ final class AphrontRequest extends Phobject { * * @param string $name Canonical header name, like `"Accept-Encoding"`. - * @param wild? $default Default value to return if header is not - present. - * @param array? $data Read this instead of `$_SERVER`. + * @param wild $default (optional) Default value to return if + header is not present. + * @param array $data (optional) Read this instead of `$_SERVER`. * @return string|wild Header value if present, or `$default` if not. */ public static function getHTTPHeader($name, $default = null, $data = null) { diff --git a/src/aphront/sink/AphrontHTTPSink.php b/src/aphront/sink/AphrontHTTPSink.php index f2a2f50860..946f94d8d6 100644 --- a/src/aphront/sink/AphrontHTTPSink.php +++ b/src/aphront/sink/AphrontHTTPSink.php @@ -29,7 +29,7 @@ abstract class AphrontHTTPSink extends Phobject { * Write an HTTP status code to the output. * * @param int $code Numeric HTTP status code. - * @param string? $message + * @param string $message (optional) * @return void */ final public function writeHTTPStatus($code, $message = '') { diff --git a/src/applications/auth/constants/PhabricatorCookies.php b/src/applications/auth/constants/PhabricatorCookies.php index 607240c97b..7a54eb3dc0 100644 --- a/src/applications/auth/constants/PhabricatorCookies.php +++ b/src/applications/auth/constants/PhabricatorCookies.php @@ -107,8 +107,8 @@ final class PhabricatorCookies extends Phobject { * * @param AphrontRequest $request Request to write to. * @param string $next_uri URI to write. - * @param bool? $force Write this cookie even if we have a - * fresh cookie already. + * @param bool $force (optional) Write this cookie even if we + * have a fresh cookie already. * @return void * * @task next diff --git a/src/applications/auth/controller/PhabricatorAuthController.php b/src/applications/auth/controller/PhabricatorAuthController.php index bb95c2ec72..7d0156dc18 100644 --- a/src/applications/auth/controller/PhabricatorAuthController.php +++ b/src/applications/auth/controller/PhabricatorAuthController.php @@ -45,8 +45,8 @@ abstract class PhabricatorAuthController extends PhabricatorController { * event and do something else if they prefer. * * @param PhabricatorUser $user User to log the viewer in as. - * @param bool? $force_full_session True to issue a full session immediately, - * bypassing MFA. + * @param bool $force_full_session (optional) True to issue a full session + * immediately, bypassing MFA. * @return AphrontResponse Response which continues the login process. */ protected function loginUser( diff --git a/src/applications/auth/engine/PhabricatorAuthSessionEngine.php b/src/applications/auth/engine/PhabricatorAuthSessionEngine.php index 30d85b6fac..2074e71f8b 100644 --- a/src/applications/auth/engine/PhabricatorAuthSessionEngine.php +++ b/src/applications/auth/engine/PhabricatorAuthSessionEngine.php @@ -327,7 +327,7 @@ final class PhabricatorAuthSessionEngine extends Phobject { * multifactor authentication. * * @param PhabricatorUser $user User whose sessions should be terminated. - * @param string|null? $except_session Optionally, one session to keep. + * @param string|null $except_session (optional) One session to keep. * Normally, the current login session. * * @return void @@ -428,9 +428,9 @@ final class PhabricatorAuthSessionEngine extends Phobject { * @param AphrontRequest $request Current request. * @param string $cancel_uri URI to return the user to if they * cancel. - * @param bool? $jump_into_hisec True to jump partial sessions - * directly into high security instead of just - * upgrading them to full sessions. + * @param bool $jump_into_hisec (optional) True to jump partial + * sessions directly into high security instead of + * just upgrading them to full sessions. * @return PhabricatorAuthHighSecurityToken Security token. * @task hisec */ @@ -742,7 +742,7 @@ final class PhabricatorAuthSessionEngine extends Phobject { * Issue a high security token for a session, if authorized. * * @param PhabricatorAuthSession $session Session to issue a token for. - * @param bool? $force Force token issue. + * @param bool $force (optional) Force token issue. * @return PhabricatorAuthHighSecurityToken|null Token, if authorized. * @task hisec */ @@ -945,11 +945,11 @@ final class PhabricatorAuthSessionEngine extends Phobject { * @param PhabricatorUser $user User to generate a URI for. * @param PhabricatorUserEmail? $email Optionally, email to verify when * link is used. - * @param string? $type Optional context string for the URI. This is purely + * @param string $type (optional) Context string for the URI. This is purely * cosmetic and used only to customize workflow and error messages. - * @param bool? $force_full_session True to generate a URI which forces an - * immediate upgrade to a full session, bypassing MFA and other login - * checks. + * @param bool $force_full_session (optional) True to generate a URI which + * forces an immediate upgrade to a full session, bypassing MFA and other + * login checks. * @return string Login URI. * @task onetime */ @@ -994,9 +994,10 @@ final class PhabricatorAuthSessionEngine extends Phobject { * Load the temporary token associated with a given one-time login key. * * @param PhabricatorUser $user User to load the token for. - * @param PhabricatorUserEmail? $email Optionally, email to verify when - * link is used. - * @param string? $key Key user is presenting as a valid one-time login key. + * @param PhabricatorUserEmail $email (optional) Email to verify when link is + * used. + * @param string $key (optional) Key user is presenting as a valid one-time + * login key. * @return PhabricatorAuthTemporaryToken|null Token, if one exists. * @task onetime */ @@ -1022,9 +1023,9 @@ final class PhabricatorAuthSessionEngine extends Phobject { * Hash a one-time login key for storage as a temporary token. * * @param PhabricatorUser $user User this key is for. - * @param PhabricatorUserEmail? $email Optionally, email to verify when - * link is used. - * @param string? $key The one time login key. + * @param PhabricatorUserEmail $email (optional) Email to verify when link is + * used. + * @param string $key (optional) The one time login key. * @return string Hash of the key. * task onetime */ diff --git a/src/applications/auth/provider/PhabricatorAuthProvider.php b/src/applications/auth/provider/PhabricatorAuthProvider.php index 4b90daa2aa..4a56ef0a3a 100644 --- a/src/applications/auth/provider/PhabricatorAuthProvider.php +++ b/src/applications/auth/provider/PhabricatorAuthProvider.php @@ -462,7 +462,8 @@ abstract class PhabricatorAuthProvider extends Phobject { * * @param AphrontRequest $request HTTP request. * @param string $mode Request mode string. - * @param map? $attributes Additional parameters, see above. + * @param map $attributes (optional) Additional parameters, see + * above. * @return wild Log in button. */ protected function renderStandardLoginButton( diff --git a/src/applications/base/PhabricatorApplication.php b/src/applications/base/PhabricatorApplication.php index 4433306e78..58ec2aa189 100644 --- a/src/applications/base/PhabricatorApplication.php +++ b/src/applications/base/PhabricatorApplication.php @@ -331,8 +331,8 @@ abstract class PhabricatorApplication * Build items for the main menu. * * @param PhabricatorUser $user The viewing user. - * @param AphrontController? $controller The current controller. May be null - * for special pages like 404, exception handlers, etc. + * @param AphrontController $controller (optional) The current controller. + * May be null for special pages like 404, exception handlers, etc. * @return list List of menu items. * @task ui */ diff --git a/src/applications/celerity/api.php b/src/applications/celerity/api.php index 98802b4598..c14f34d919 100644 --- a/src/applications/celerity/api.php +++ b/src/applications/celerity/api.php @@ -11,7 +11,7 @@ * * @param string $symbol Name of the celerity module to include. This is * whatever you annotated as "@provides" in the file. - * @param string? $source_name + * @param string $source_name (optional) * @return void */ function require_celerity_resource($symbol, $source_name = 'phabricator') { @@ -42,7 +42,7 @@ function celerity_generate_unique_node_id() { * Get the versioned URI for a raw resource, like an image. * * @param string $resource Path to the raw image. - * @param string? $source + * @param string $source (optional) Defaults to 'phabricator' * @return string Versioned path to the image, if one is available. */ function celerity_get_resource_uri($resource, $source = 'phabricator') { diff --git a/src/applications/differential/render/DifferentialChangesetHTMLRenderer.php b/src/applications/differential/render/DifferentialChangesetHTMLRenderer.php index f6832c4fc9..eff9df9c83 100644 --- a/src/applications/differential/render/DifferentialChangesetHTMLRenderer.php +++ b/src/applications/differential/render/DifferentialChangesetHTMLRenderer.php @@ -494,7 +494,7 @@ abstract class DifferentialChangesetHTMLRenderer * @param int $top Beginning of the line range to build links for. * @param int $len Length of the line range to build links for. * @param int $changeset_length Total number of lines in the changeset. - * @param bool? $is_blocks + * @param bool $is_blocks (optional) * @return markup Rendered links. */ protected function renderShowContextLinks( diff --git a/src/applications/diffusion/data/DiffusionGitBranch.php b/src/applications/diffusion/data/DiffusionGitBranch.php index 75c17b67c1..7914c69874 100644 --- a/src/applications/diffusion/data/DiffusionGitBranch.php +++ b/src/applications/diffusion/data/DiffusionGitBranch.php @@ -20,8 +20,8 @@ final class DiffusionGitBranch extends Phobject { * ); * * @param string $stdout stdout of git branch command. - * @param string? $only_this_remote Filter branches to those on a specific - * remote. + * @param string $only_this_remote (optional) Filter branches to those on a + * specific remote. * @return map Map of 'branch' or 'remote/branch' to hash at HEAD. */ public static function parseRemoteBranchOutput( diff --git a/src/applications/diffusion/request/DiffusionRequest.php b/src/applications/diffusion/request/DiffusionRequest.php index d9bd30afea..eb1eaf9722 100644 --- a/src/applications/diffusion/request/DiffusionRequest.php +++ b/src/applications/diffusion/request/DiffusionRequest.php @@ -135,7 +135,7 @@ abstract class DiffusionRequest extends Phobject { * * @param string $identifier Repository identifier. * @param PhabricatorUser $viewer Viewing user. - * @param bool? $need_edit + * @param bool $need_edit (optional) * @return DiffusionRequest New request object. * @task new */ diff --git a/src/applications/files/PhabricatorImageTransformer.php b/src/applications/files/PhabricatorImageTransformer.php index 0ca475e90c..bcfc1745ed 100644 --- a/src/applications/files/PhabricatorImageTransformer.php +++ b/src/applications/files/PhabricatorImageTransformer.php @@ -21,7 +21,7 @@ final class PhabricatorImageTransformer extends Phobject { * extensions), but can save images in another format. * * @param resource $data GD image resource. - * @param string? $preferred_mime Optionally, preferred mime type. + * @param string $preferred_mime (optional) Preferred mime type. * @return string Bytes of an image file. * @task save */ diff --git a/src/applications/files/storage/PhabricatorFile.php b/src/applications/files/storage/PhabricatorFile.php index 3da430d95c..fbb6f788f0 100644 --- a/src/applications/files/storage/PhabricatorFile.php +++ b/src/applications/files/storage/PhabricatorFile.php @@ -807,8 +807,8 @@ final class PhabricatorFile extends PhabricatorFileDAO /** * Return an iterable which emits file content bytes. * - * @param int? $begin Offset for the start of data. - * @param int? $end Offset for the end of data. + * @param int $begin (optional) Offset for the start of data. + * @param int $end (optional) Offset for the end of data. * @return Iterable Iterable object which emits requested data. */ public function getFileDataIterator($begin = null, $end = null) { diff --git a/src/applications/meta/panel/PhabricatorApplicationConfigurationPanel.php b/src/applications/meta/panel/PhabricatorApplicationConfigurationPanel.php index 944daa9e08..5d62fd1a05 100644 --- a/src/applications/meta/panel/PhabricatorApplicationConfigurationPanel.php +++ b/src/applications/meta/panel/PhabricatorApplicationConfigurationPanel.php @@ -27,7 +27,7 @@ abstract class PhabricatorApplicationConfigurationPanel /** * Get the URI for this application configuration panel. * - * @param string? $path Optional path to append. + * @param string $path (optional) Path to append. * @return string Relative URI for the panel. */ public function getPanelURI($path = '') { diff --git a/src/applications/metamta/storage/PhabricatorMetaMTAMail.php b/src/applications/metamta/storage/PhabricatorMetaMTAMail.php index 2d1ec54bb9..826c950577 100644 --- a/src/applications/metamta/storage/PhabricatorMetaMTAMail.php +++ b/src/applications/metamta/storage/PhabricatorMetaMTAMail.php @@ -456,8 +456,8 @@ final class PhabricatorMetaMTAMail * * @param string $thread_id Unique identifier, appropriate for use in a * Message-ID, In-Reply-To or References headers. - * @param bool? $is_first_message If true, indicates this is the first - * message in the thread. + * @param bool $is_first_message (optional) If true, indicates this is the + * first message in the thread. * @return this */ public function setThreadID($thread_id, $is_first_message = false) { diff --git a/src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php b/src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php index 8294f6832e..2ed1af8e00 100644 --- a/src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php +++ b/src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php @@ -341,8 +341,8 @@ final class PhabricatorRepositoryPullLocalDaemon * With the `$consume` flag, an internal cursor will also be incremented so * that these messages are not returned by subsequent calls. * - * @param bool? $consume Pass `true` to consume these messages, so the - * process will not see them again. + * @param bool $consume (optional) Pass `true` to consume these messages, so + * the process will not see them again. * @return list Pending update messages. * * @task pull diff --git a/src/applications/repository/graphcache/PhabricatorRepositoryGraphCache.php b/src/applications/repository/graphcache/PhabricatorRepositoryGraphCache.php index 2d9c36fae7..f42ef9c6c1 100644 --- a/src/applications/repository/graphcache/PhabricatorRepositoryGraphCache.php +++ b/src/applications/repository/graphcache/PhabricatorRepositoryGraphCache.php @@ -236,8 +236,8 @@ final class PhabricatorRepositoryGraphCache extends Phobject { * to force a cache update by passing the existing data to `$rebuild_data`. * * @param int $bucket_key Bucket key, from @{method:getBucketKey}. - * @param mixed? $rebuild_data Current data, to force a cache rebuild of - * this bucket. + * @param mixed $rebuild_data (optional) Current data, to force a cache + * rebuild of this bucket. * @return array Data from the cache. * @task cache */ diff --git a/src/applications/repository/storage/PhabricatorRepository.php b/src/applications/repository/storage/PhabricatorRepository.php index 5ffaad6282..07daf32e16 100644 --- a/src/applications/repository/storage/PhabricatorRepository.php +++ b/src/applications/repository/storage/PhabricatorRepository.php @@ -1645,7 +1645,8 @@ final class PhabricatorRepository extends PhabricatorRepositoryDAO * 2037). We adjust the pull frequency based on when the most recent commit * occurred. * - * @param int? $minimum The minimum update interval to use, in seconds. + * @param int $minimum (optional) The minimum update interval to use, in + * seconds. * @return int Repository update interval, in seconds. */ public function loadUpdateInterval($minimum = 15) { @@ -2113,7 +2114,8 @@ final class PhabricatorRepository extends PhabricatorRepositoryDAO * For lower-level service resolution, see @{method:getAlmanacServiceURI}. * * @param PhabricatorUser $viewer Viewing user. - * @param bool? $never_proxy `true` to throw if a client would be returned. + * @param bool $never_proxy (optional) `true` to throw if a client would be + * returned. * @return ConduitClient|null Client, or `null` for local repositories. */ public function newConduitClient( diff --git a/src/applications/search/engine/PhabricatorApplicationSearchEngine.php b/src/applications/search/engine/PhabricatorApplicationSearchEngine.php index 1979ec092a..2458a1ccd6 100644 --- a/src/applications/search/engine/PhabricatorApplicationSearchEngine.php +++ b/src/applications/search/engine/PhabricatorApplicationSearchEngine.php @@ -732,7 +732,7 @@ abstract class PhabricatorApplicationSearchEngine extends Phobject { * * @param AphrontRequest $request Request to read user PHIDs from. * @param string $key Key to read in the request. - * @param list? $allow_types Other permitted PHID types. + * @param list $allow_types (optional) Other permitted PHID types. * @return list List of user PHIDs and selector functions. * @task read */ @@ -807,7 +807,7 @@ abstract class PhabricatorApplicationSearchEngine extends Phobject { * * @param AphrontRequest $request Request to read PHIDs from. * @param string $key Key to read in the request. - * @param list? $allow_types Optional, list of permitted PHID + * @param list $allow_types (optional) List of permitted PHID * types. * @return list List of object PHIDs. * diff --git a/src/applications/settings/panel/PhabricatorSettingsPanel.php b/src/applications/settings/panel/PhabricatorSettingsPanel.php index ac92a134c6..e5dc33fa78 100644 --- a/src/applications/settings/panel/PhabricatorSettingsPanel.php +++ b/src/applications/settings/panel/PhabricatorSettingsPanel.php @@ -234,7 +234,7 @@ abstract class PhabricatorSettingsPanel extends Phobject { /** * Get the URI for this panel. * - * @param string? $path Optional path to append. + * @param string $path (optional) Path to append. * @return string Relative URI for the panel. * @task panel */ diff --git a/src/applications/transactions/editengine/PhabricatorEditEngine.php b/src/applications/transactions/editengine/PhabricatorEditEngine.php index 6b3aae2790..f86b4773bf 100644 --- a/src/applications/transactions/editengine/PhabricatorEditEngine.php +++ b/src/applications/transactions/editengine/PhabricatorEditEngine.php @@ -713,8 +713,8 @@ abstract class PhabricatorEditEngine * to make Conduit a little easier to use. * * @param wild $identifier ID, PHID, or monogram. - * @param list? $capabilities List of required capability constants, - * or omit for defaults. + * @param list $capabilities (optional) List of required capability + * constants, or omit for defaults. * @return object Corresponding editable object. * @task load */ @@ -793,8 +793,8 @@ abstract class PhabricatorEditEngine * Load an object by ID. * * @param int $id Object ID. - * @param list? $capabilities List of required capability constants, - * or omit for defaults. + * @param list $capabilities (optional) List of required capability + * constants, or omit for defaults. * @return object|null Object, or null if no such object exists. * @task load */ @@ -810,8 +810,8 @@ abstract class PhabricatorEditEngine * Load an object by PHID. * * @param phid $phid Object PHID. - * @param list? $capabilities List of required capability constants, - * or omit for defaults. + * @param list $capabilities (optional) List of required capability + * constants, or omit for defaults. * @return object|null Object, or null if no such object exists. * @task load */ @@ -827,8 +827,8 @@ abstract class PhabricatorEditEngine * Load an object given a configured query. * * @param PhabricatorPolicyAwareQuery $query Configured query. - * @param list? $capabilities List of required capability constants, - * or omit for defaults. + * @param list $capabilities (optional) List of required capability + * constants, or omit for defaults. * @return object|null Object, or null if no such object exists. * @task load */ diff --git a/src/infrastructure/cache/PhutilKeyValueCache.php b/src/infrastructure/cache/PhutilKeyValueCache.php index e65eb9675c..45f7a3048e 100644 --- a/src/infrastructure/cache/PhutilKeyValueCache.php +++ b/src/infrastructure/cache/PhutilKeyValueCache.php @@ -31,7 +31,7 @@ abstract class PhutilKeyValueCache extends Phobject { * once. * * @param string $key Key to retrieve. - * @param wild? $default Optional value to return if the key is not + * @param wild $default (optional) Value to return if the key is not * found. By default, returns null. * @return wild Cache value (on cache hit) or default value (on cache * miss). @@ -51,7 +51,7 @@ abstract class PhutilKeyValueCache extends Phobject { * * @param string $key Key to set. * @param wild $value Value to set. - * @param int|null? $ttl Optional TTL. + * @param int|null $ttl (optional) TTL. * @return this * @task kvimpl */ @@ -93,7 +93,7 @@ abstract class PhutilKeyValueCache extends Phobject { * policy and data will persist in cache indefinitely. * * @param dict $keys Map of cache keys to values. - * @param int|null? $ttl TTL for cache keys, in seconds. + * @param int|null $ttl (optional) TTL for cache keys, in seconds. * @return this * @task kvimpl */ diff --git a/src/infrastructure/contentsource/PhabricatorContentSource.php b/src/infrastructure/contentsource/PhabricatorContentSource.php index 19f954e0d8..600f3080bf 100644 --- a/src/infrastructure/contentsource/PhabricatorContentSource.php +++ b/src/infrastructure/contentsource/PhabricatorContentSource.php @@ -23,9 +23,9 @@ abstract class PhabricatorContentSource extends Phobject { * Construct a new content source object. * * @param const $source The source type constant to build a source for. - * @param array? $params Source parameters. - * @param bool? $force True to suppress errors and force construction of a - * source even if the source type is not valid. + * @param array $params (optional) Source parameters. + * @param bool $force (optional) True to suppress errors and force + * construction of a source even if the source type is not valid. * @return PhabricatorContentSource New source object. */ final public static function newForSource( diff --git a/src/infrastructure/daemon/PhutilDaemonHandle.php b/src/infrastructure/daemon/PhutilDaemonHandle.php index a44ba7b7cb..36b0ea9935 100644 --- a/src/infrastructure/daemon/PhutilDaemonHandle.php +++ b/src/infrastructure/daemon/PhutilDaemonHandle.php @@ -329,7 +329,7 @@ final class PhutilDaemonHandle extends Phobject { * Dispatch an event to event listeners. * * @param string $type Event type. - * @param dict? $params Event parameters. + * @param dict $params (optional) Event parameters. * @return void */ private function dispatchEvent($type, array $params = array()) { diff --git a/src/infrastructure/daemon/workers/PhabricatorWorker.php b/src/infrastructure/daemon/workers/PhabricatorWorker.php index 69815557ec..c5c8271862 100644 --- a/src/infrastructure/daemon/workers/PhabricatorWorker.php +++ b/src/infrastructure/daemon/workers/PhabricatorWorker.php @@ -232,7 +232,7 @@ abstract class PhabricatorWorker extends Phobject { * * @param string $class Task class to queue. * @param array $data Data for the followup task. - * @param array? $options Options for the followup task. + * @param array $options (optional) Options for the followup task. * @return this */ final protected function queueTask( @@ -261,7 +261,7 @@ abstract class PhabricatorWorker extends Phobject { * this method to force the queue to flush before failing (for example, if * you are using queues to improve locking behavior). * - * @param map? $defaults Optional default options. + * @param map $defaults (optional) Default options. */ final public function flushTaskQueue($defaults = array()) { foreach ($this->getQueuedTasks() as $task) { diff --git a/src/infrastructure/edges/editor/PhabricatorEdgeEditor.php b/src/infrastructure/edges/editor/PhabricatorEdgeEditor.php index 8ab8ddce58..e1410cfd13 100644 --- a/src/infrastructure/edges/editor/PhabricatorEdgeEditor.php +++ b/src/infrastructure/edges/editor/PhabricatorEdgeEditor.php @@ -48,7 +48,7 @@ final class PhabricatorEdgeEditor extends Phobject { * @param phid $src Source object PHID. * @param const $type Edge type constant. * @param phid $dst Destination object PHID. - * @param map? $options Options map (see documentation). + * @param map $options (optional) Options map (see documentation). * @return this * * @task edit diff --git a/src/infrastructure/edges/query/PhabricatorEdgeQuery.php b/src/infrastructure/edges/query/PhabricatorEdgeQuery.php index eeb6123abf..a33d75cfcc 100644 --- a/src/infrastructure/edges/query/PhabricatorEdgeQuery.php +++ b/src/infrastructure/edges/query/PhabricatorEdgeQuery.php @@ -256,8 +256,10 @@ final class PhabricatorEdgeQuery extends PhabricatorQuery { * $object->attachHandles(array_select_keys($handles, $dst_phids)); * } * - * @param list? $src_phids List of PHIDs to select, or empty to select all. - * @param list? $types List of edge types to select, or empty to select all. + * @param list $src_phids (optional) List of PHIDs to select, or empty to + * select all. + * @param list $types (optional) List of edge types to select, or empty to + * select all. * @return list List of matching destination PHIDs. */ public function getDestinationPHIDs( diff --git a/src/infrastructure/markup/PhabricatorMarkupEngine.php b/src/infrastructure/markup/PhabricatorMarkupEngine.php index 89f03977f8..60ea048458 100644 --- a/src/infrastructure/markup/PhabricatorMarkupEngine.php +++ b/src/infrastructure/markup/PhabricatorMarkupEngine.php @@ -59,8 +59,8 @@ final class PhabricatorMarkupEngine extends Phobject { * @param PhabricatorMarkupInterface $object The object to render. * @param string $field The field to render. * @param PhabricatorUser $viewer User viewing the markup. - * @param object? $context_object A context object for - * policy checks. + * @param object $context_object (optional) A context + * object for policy checks. * @return string Marked up output. * @task markup */ @@ -196,7 +196,7 @@ final class PhabricatorMarkupEngine extends Phobject { * @param string $field The field to retrieve. * @param string $metadata_key The engine metadata field * to retrieve. - * @param wild? $default Optional default value. + * @param wild $default (optional) Default value. * @task markup */ public function getEngineMetadata( diff --git a/src/infrastructure/markup/PhutilMarkupEngine.php b/src/infrastructure/markup/PhutilMarkupEngine.php index 7f650a4417..aadb891116 100644 --- a/src/infrastructure/markup/PhutilMarkupEngine.php +++ b/src/infrastructure/markup/PhutilMarkupEngine.php @@ -22,8 +22,8 @@ abstract class PhutilMarkupEngine extends Phobject { * metadata may be available in your configuration. * * @param string $key Key to retrieve from metadata. - * @param mixed? $default Default value to return if the key is not - * available. + * @param mixed $default (optional) Default value to return if the key is + * not available. * @return mixed Metadata property, or default value. */ abstract public function getTextMetadata($key, $default = null); diff --git a/src/infrastructure/markup/markuprule/PhutilRemarkupRule.php b/src/infrastructure/markup/markuprule/PhutilRemarkupRule.php index 6513d0f66c..09f6ae9a5c 100644 --- a/src/infrastructure/markup/markuprule/PhutilRemarkupRule.php +++ b/src/infrastructure/markup/markuprule/PhutilRemarkupRule.php @@ -62,7 +62,7 @@ abstract class PhutilRemarkupRule extends Phobject { * * @param string $name Tag name. * @param dict $attrs Tag attributes. - * @param wild? $content Tag content. + * @param wild $content (optional) Tag content. * @return PhutilSafeHTML Tag object. */ protected function newTag($name, array $attrs, $content = null) { diff --git a/src/infrastructure/markup/render.php b/src/infrastructure/markup/render.php index eaa4e067b2..fda35d72e8 100644 --- a/src/infrastructure/markup/render.php +++ b/src/infrastructure/markup/render.php @@ -17,8 +17,8 @@ * parameters. * * @param string $tag The name of the tag, like `a` or `div`. - * @param map? $attributes A map of tag attributes. - * @param wild? $content Content to put in the tag. + * @param map $attributes (optional) A map of tag attributes. + * @param wild $content (optional) Content to put in the tag. * @return PhutilSafeHTML Tag object. */ function phutil_tag($tag, array $attributes = array(), $content = null) { diff --git a/src/infrastructure/storage/lisk/LiskDAO.php b/src/infrastructure/storage/lisk/LiskDAO.php index 1915bd71ee..db6554bacb 100644 --- a/src/infrastructure/storage/lisk/LiskDAO.php +++ b/src/infrastructure/storage/lisk/LiskDAO.php @@ -264,7 +264,7 @@ abstract class LiskDAO extends Phobject * * @param mode $mode Connection mode. * @param AphrontDatabaseConnection $connection Connection to cache. - * @param bool? $force_unique + * @param bool $force_unique (optional) * @return this * @task conn */ @@ -802,8 +802,9 @@ abstract class LiskDAO extends Phobject * Get or build the database connection for this object. * * @param string $mode 'r' for read, 'w' for read/write. - * @param bool? $force_new True to force a new connection. The connection - * will not be retrieved from or saved into the connection cache. + * @param bool $force_new (optional) True to force a new connection. The + * connection will not be retrieved from or saved into the connection + * cache. * @return AphrontDatabaseConnection Lisk connection object. * * @task info diff --git a/src/infrastructure/util/PhabricatorHash.php b/src/infrastructure/util/PhabricatorHash.php index 2b3fe8ab4c..7c49703553 100644 --- a/src/infrastructure/util/PhabricatorHash.php +++ b/src/infrastructure/util/PhabricatorHash.php @@ -12,7 +12,7 @@ final class PhabricatorHash extends Phobject { * weak. Callers should prefer @{method:digestWithNamedKey}. * * @param string $string Input string. - * @param string? $key + * @param string $key (optional) * @return string 32-byte hexadecimal SHA1+HMAC hash. */ public static function weakDigest($string, $key = null) { diff --git a/src/view/phui/PHUICrumbsView.php b/src/view/phui/PHUICrumbsView.php index bd202ed5a7..80613cb61e 100644 --- a/src/view/phui/PHUICrumbsView.php +++ b/src/view/phui/PHUICrumbsView.php @@ -16,7 +16,7 @@ final class PHUICrumbsView extends AphrontView { * a link. * * @param string $text Text of the crumb. - * @param string? $href Optional href for the crumb. + * @param string $href (optional) href for the crumb. * @return this */ public function addTextCrumb($text, $href = null) { diff --git a/support/startup/PhabricatorStartup.php b/support/startup/PhabricatorStartup.php index 38c8af13b1..0315c0759f 100644 --- a/support/startup/PhabricatorStartup.php +++ b/support/startup/PhabricatorStartup.php @@ -344,10 +344,10 @@ final class PhabricatorStartup { * Fatal the request completely, sending a plain text message to the client. * * @param string $message Plain text message to send to the client. - * @param string? $log_message Plain text message to send to the error log. - * If not provided, the client message is used. You can pass - * a more detailed message here (e.g., with stack traces) to - * avoid showing it to users. + * @param string $log_message (optional) Plain text message to send to the + * error log. If not provided, the client message is used. + * You can pass a more detailed message here (e.g., with + * stack traces) to avoid showing it to users. * @return exit This method **does not return**. * * @task apocalypse diff --git a/support/startup/preamble-utils.php b/support/startup/preamble-utils.php index c04f06b900..d08f51b69e 100644 --- a/support/startup/preamble-utils.php +++ b/support/startup/preamble-utils.php @@ -4,7 +4,7 @@ * Parse the "X_FORWARDED_FOR" HTTP header to determine the original client * address. * - * @param int? $layers Number of devices to trust. + * @param int $layers (optional) Number of devices to trust. * @return void */ function preamble_trust_x_forwarded_for_header($layers = 1) {