Merge "Fix wrong @return type hints in Language::tsTo… methods"
[lhc/web/wiklou.git] / includes / session / Session.php
index 96e8d50..4188f4f 100644 (file)
@@ -124,6 +124,13 @@ final class Session implements \Countable, \Iterator, \ArrayAccess {
                $this->backend->persist();
        }
 
+       /**
+        * Make this session not be persisted across requests
+        */
+       public function unpersist() {
+               $this->backend->unpersist();
+       }
+
        /**
         * Indicate whether the user should be remembered independently of the
         * session ID.
@@ -328,7 +335,7 @@ final class Session implements \Countable, \Iterator, \ArrayAccess {
         *
         * @param string|string[] $salt Token salt
         * @param string $key Token key
-        * @return MediaWiki\\Session\\SessionToken
+        * @return Token
         */
        public function getToken( $salt = '', $key = 'default' ) {
                $new = false;
@@ -345,7 +352,7 @@ final class Session implements \Countable, \Iterator, \ArrayAccess {
                        $new = true;
                }
                if ( is_array( $salt ) ) {
-                       $salt = join( '|', $salt );
+                       $salt = implode( '|', $salt );
                }
                return new Token( $secret, (string)$salt, $new );
        }