X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=docs%2Fhooks.txt;h=976d5c2a944a4e659781855d28207b9df22798b2;hb=9376151781993de3ce151deb7f90f03cc5e25af3;hp=b2f1e816b58c7640be740388a058f074a418e15e;hpb=27a6845c2a675990b04dfead674c0d46d140aa17;p=lhc%2Fweb%2Fwiklou.git diff --git a/docs/hooks.txt b/docs/hooks.txt index b2f1e816b5..976d5c2a94 100644 --- a/docs/hooks.txt +++ b/docs/hooks.txt @@ -965,8 +965,8 @@ form via the Preferences form. 'ChangesListInitRows': Batch process change list rows prior to rendering. $changesList: ChangesList instance -$rows: The data that will be rendered. May be a ResultWrapper instance or - an array. +$rows: The data that will be rendered. May be a \Wikimedia\Rdbms\IResultWrapper + instance or an array. 'ChangesListInsertArticleLink': Override or augment link to article in RC list. &$changesList: ChangesList instance. @@ -2448,7 +2448,7 @@ $title: Title object &$pageLang: the page content language. Input can be anything (under control of hook subscribers), but hooks should return Language objects. Language code strings are deprecated. -$userLang: the user language (Language or StubUserLang object) +$userLang: the user language (Language object) 'PageContentSave': Before an article is saved. $wikiPage: the WikiPage (object) being saved @@ -3068,7 +3068,6 @@ $tooltip: The default tooltip. Escape before using. - text - String for the text - attribs - Array of attributes - query - Array of query parameters to add to the URL - - options - Array of options for Linker::link $lang: The language code to use for the link in the wfMessage function 'SkinGetPoweredBy': TODO @@ -3569,7 +3568,10 @@ hook. If your extension absolutely, positively must prevent some files from being uploaded, use UploadVerifyFile or UploadVerifyUpload. $upload: (object) An instance of UploadBase, with all info about the upload $user: (object) An instance of User, the user uploading this file -$props: (array) File properties, as returned by FSFile::getPropsFromPath() +$props: (array|null) File properties, as returned by + MWFileProps::getPropsFromPath(). Note this is not always guaranteed to be set, + e.g. in test scenarios. Call MWFileProps::getPropsFromPath() yourself in case + you need the information. &$error: output: If the file stashing should be prevented, set this to the reason in the form of [ messagename, param1, param2, ... ] or a MessageSpecifier instance (you might want to use ApiMessage to provide machine @@ -3598,7 +3600,10 @@ MIME type (same as UploadVerifyFile) and the information entered by the user (upload comment, file page contents etc.). $upload: (object) An instance of UploadBase, with all info about the upload $user: (object) An instance of User, the user uploading this file -$props: (array) File properties, as returned by FSFile::getPropsFromPath() +$props: (array|null) File properties, as returned by + MWFileProps::getPropsFromPath(). Note this is not always guaranteed to be set, + e.g. in test scenarios. Call MWFileProps::getPropsFromPath() yourself in case + you need the information. $comment: (string) Upload log comment (also used as edit summary) $pageText: (string) File description page text (only used for new uploads) &$error: output: If the file upload should be prevented, set this to the reason