Bug_85482.patch

Presedo Roberto, 2018-07-05 01:27

Download (1.62 KB)

View differences:

typo3/sysext/core/Classes/Authentication/BackendUserAuthentication.php (revision )
1307 1307
        $this->groupData['webmounts'] = implode(',', array_unique($mountPointUids));
1308 1308
    }
1309 1309

  
1310

  
1311
    /**
1312
     * Checks that the user is not admin AND does not include ROOT mountpoint (0) if multiple mountpoint are set
1313
     */
1314
    public function cleanWebmounts() {
1315
        if (!$this->isAdmin()){
1316
            $currentWebMounts = array_unique(GeneralUtility::intExplode(',', $this->dataLists["webmount_list"]));
1317
            foreach ($currentWebMounts AS $key => $pid) {
1318
                if ($pid === 0) {
1319
                    unset($currentWebMounts[$key]);
1320
                }
1321
            }
1322
            $this->dataLists["webmount_list"] = implode(',', array_unique($currentWebMounts));
1323
        }
1324
    }
1325

  
1310 1326
    /**
1311 1327
     * Returns TRUE or FALSE, depending if an alert popup (a javascript confirmation) should be shown
1312 1328
     * call like $GLOBALS['BE_USER']->jsConfirmation($BITMASK).
......
1563 1579
                }
1564 1580
            }
1565 1581
        }
1582

  
1583
        $this->cleanWebmounts();
1584

  
1566 1585
        // HOOK: fetchGroups_postProcessing
1567 1586
        foreach ($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_userauthgroup.php']['fetchGroups_postProcessing'] ?? [] as $_funcRef) {
1568 1587
            $_params = [];