Skip to content

Commit ccff67d

Browse files
committed
fix: invalid merge on backport
Signed-off-by: Grigorii K. Shartsev <[email protected]>
1 parent 05f0e6b commit ccff67d

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

lib/AppInfo/Application.php

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -93,15 +93,9 @@ public function boot(IBootContext $context): void {
9393
}
9494

9595
public function registerFrontend(IRequest $request, IConfig $config, IUserSession $userSession): void {
96-
if (!\OC::$CLI) {
97-
if ($userSession->getUser() instanceof IUser
98-
&& strpos($request->getPathInfo(), '/s/') !== 0
99-
&& strpos($request->getPathInfo(), '/login/') !== 0
100-
&& substr($request->getScriptName(), 0 - strlen('/index.php')) === '/index.php') {
101-
Util::addScript('terms_of_service', 'terms_of_service-user');
102-
} else if ($config->getAppValue(self::APPNAME, 'tos_on_public_shares', '0') === '1') {
103-
Util::addScript('terms_of_service', 'terms_of_service-public');
104-
}
96+
// Ignore CLI
97+
if (\OC::$CLI) {
98+
return;
10599
}
106100

107101
// Skip login-related pages

0 commit comments

Comments
 (0)