after doing a database restore, the permission may not yet exist (#6930)
This commit is contained in:
parent
2cfbe63a5f
commit
ff55a36980
|
|
@ -46,7 +46,7 @@ if (!class_exists('permissions')) {
|
|||
* @var string $permission
|
||||
*/
|
||||
public function delete($permission, $type) {
|
||||
if ($this->exists($permission)) {
|
||||
if ($this->exists($permission) && !empty($_SESSION["permissions"][$permission])) {
|
||||
if ($type === "temp") {
|
||||
if ($_SESSION["permissions"][$permission] === "temp") {
|
||||
unset($_SESSION["permissions"][$permission]);
|
||||
|
|
|
|||
Loading…
Reference in New Issue