core will handle invalid URLs and redirects properly
This commit is contained in:
parent
a743047e82
commit
2f98f64241
|
@ -965,20 +965,6 @@ class OC_Util {
|
|||
OC_Template::printGuestPage("", "login", $parameters);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Check if the app is enabled, redirects to home if not
|
||||
*
|
||||
* @param string $app
|
||||
* @return void
|
||||
*/
|
||||
public static function checkAppEnabled($app) {
|
||||
if (!OC_App::isEnabled($app)) {
|
||||
header('Location: ' . \OCP\Util::linkToAbsolute('', 'index.php'));
|
||||
exit();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if the user is logged in, redirects to home if not. With
|
||||
* redirect URL parameter to the request URI.
|
||||
|
|
|
@ -136,9 +136,9 @@ class App {
|
|||
* @param string $app
|
||||
* @return void
|
||||
* @since 4.0.0
|
||||
* @deprecated 9.0.0 ownCloud core will handle disabled apps and redirects to valid URLs
|
||||
*/
|
||||
public static function checkAppEnabled( $app ) {
|
||||
\OC_Util::checkAppEnabled( $app );
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue