mirror of
https://github.com/wbbaddons/Tims-Chat.git
synced 2024-12-22 21:40:08 +00:00
Hide PageMenuItem for guests
They cannot view the page anyway ;)
This commit is contained in:
parent
94467d9103
commit
96e835e738
@ -17,6 +17,9 @@ class ChatPageMenuItemProvider extends DefaultPageMenuItemProvider {
|
|||||||
* @see wcf\system\menu\page\PageMenuItemProvider::isVisible()
|
* @see wcf\system\menu\page\PageMenuItemProvider::isVisible()
|
||||||
*/
|
*/
|
||||||
public function isVisible() {
|
public function isVisible() {
|
||||||
|
// guests are not supported
|
||||||
|
if (!WCF::getUser()->userID) return false;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
\wcf\data\chat\room\ChatRoom::getCache()->seek(0);
|
\wcf\data\chat\room\ChatRoom::getCache()->seek(0);
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user