* @return (string|array)[] Returning a string will use that as the salt
* for User::getEditTokenObject() to fetch the token, which will give a
* LoggedOutEditToken (always "+\\") for anonymous users. Returning an
* @return (string|array)[] Returning a string will use that as the salt
* for User::getEditTokenObject() to fetch the token, which will give a
* LoggedOutEditToken (always "+\\") for anonymous users. Returning an
* which will always return a full token even for anonymous users.
*/
public static function getTokenTypeSalts() {
* which will always return a full token even for anonymous users.
*/
public static function getTokenTypeSalts() {
* @param string|array $salt A string will be used as the salt for
* User::getEditTokenObject() to fetch the token, which will give a
* LoggedOutEditToken (always "+\\") for anonymous users. An array will
* @param string|array $salt A string will be used as the salt for
* User::getEditTokenObject() to fetch the token, which will give a
* LoggedOutEditToken (always "+\\") for anonymous users. An array will
* will always return a full token even for anonymous users. An array will
* also persist the session.
* will always return a full token even for anonymous users. An array will
* also persist the session.
*/
public static function getToken( User $user, MediaWiki\Session\Session $session, $salt ) {
if ( is_array( $salt ) ) {
*/
public static function getToken( User $user, MediaWiki\Session\Session $session, $salt ) {
if ( is_array( $salt ) ) {