Error reported using YII exit function, logout? not found

sign out as written in the document:

Yii::app()->user->logout();

the result reported a 500 error.

ERROR: 2018-06-28 14:18:20 ip[127.0.0.1] requestId[951106107] [exception.CException] callId[0] []    CException: Session and its behaviors do not have a method or closure named "logout". in
Mar.29,2021

from the error message, the logout method was not found, and the magic method was performed, but still not. It should be that User comment is not configured correctly so that the user corresponding to app is not a subclass of yiiwebUser. It is also possible that because there is no login, user is a guest identity, but this should not be the case with the error message.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3b275-2c286.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3b275-2c286.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?