mirror of
https://github.com/the-djmaze/snappymail.git
synced 2025-01-01 04:22:15 +08:00
Nextcloud /appinfo/app.php is deprecated https://github.com/pierre-alain-b/rainloop-nextcloud/issues/264
Also see #96
This commit is contained in:
parent
e7a54e69d1
commit
bdca1f4ff6
2 changed files with 19 additions and 16 deletions
|
@ -1,13 +0,0 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* Nextcloud - SnappyMail mail plugin
|
||||
*
|
||||
* @author SnappyMail Team, Nextgen-Networks (@nextgen-networks), Tab Fitts (@tabp0le), Pierre-Alain Bandinelli (@pierre-alain-b)
|
||||
*
|
||||
* Based initially on https://github.com/SnappyMail/snappymail-webmail/tree/master/build/owncloud
|
||||
*/
|
||||
|
||||
$app = new OCA\SnappyMail\AppInfo\Application();
|
||||
$app->registerNavigation();
|
||||
$app->getContainer()->query('SnappyMailHelper')->registerHooks();
|
|
@ -7,12 +7,27 @@ use OCA\SnappyMail\Controller\AjaxController;
|
|||
use OCA\SnappyMail\Controller\PageController;
|
||||
|
||||
use OCP\AppFramework\App;
|
||||
use OCP\AppFramework\Bootstrap\IBootstrap;
|
||||
use OCP\AppFramework\Bootstrap\IRegistrationContext;
|
||||
use OCP\AppFramework\Bootstrap\IBootContext;
|
||||
use OCP\IL10N;
|
||||
use OCP\IUser;
|
||||
|
||||
class Application extends App {
|
||||
class Application extends App implements IBootstrap
|
||||
{
|
||||
|
||||
public function __construct(array $urlParams = []) {
|
||||
public function register(IRegistrationContext $context): void
|
||||
{
|
||||
}
|
||||
|
||||
public function boot(IBootContext $context): void
|
||||
{
|
||||
$this->registerNavigation();
|
||||
$this->getContainer()->query('SnappyMailHelper')->registerHooks();
|
||||
}
|
||||
|
||||
public function __construct(array $urlParams = [])
|
||||
{
|
||||
parent::__construct('snappymail', $urlParams);
|
||||
|
||||
$container = $this->getContainer();
|
||||
|
@ -56,7 +71,8 @@ class Application extends App {
|
|||
\OCP\Util::addScript('snappymail', 'snappymail');
|
||||
}
|
||||
|
||||
public function registerNavigation() {
|
||||
public function registerNavigation()
|
||||
{
|
||||
$container = $this->getContainer();
|
||||
|
||||
$container->query('OCP\INavigationManager')->add(function () use ($container) {
|
||||
|
|
Loading…
Reference in a new issue