1
|
|
|
<?php |
2
|
|
|
/** |
3
|
|
|
* Audioplayer |
4
|
|
|
* |
5
|
|
|
* This file is licensed under the Affero General Public License version 3 or |
6
|
|
|
* later. See the LICENSE.md file. |
7
|
|
|
* |
8
|
|
|
* @author Marcel Scherello <[email protected]> |
9
|
|
|
* @copyright 2020 Marcel Scherello |
10
|
|
|
*/ |
11
|
|
|
|
12
|
|
|
namespace OCA\audioplayer\AppInfo; |
13
|
|
|
|
14
|
|
|
use OCA\audioplayer\Dashboard\Widget; |
15
|
|
|
use OCA\audioplayer\Listener\LoadAdditionalScripts; |
16
|
|
|
use OCA\audioplayer\Search\Provider; |
17
|
|
|
use OCA\Files_Sharing\Event\BeforeTemplateRenderedEvent; |
|
|
|
|
18
|
|
|
use OCP\AppFramework\App; |
19
|
|
|
use OCP\AppFramework\Bootstrap\IBootContext; |
20
|
|
|
use OCP\AppFramework\Bootstrap\IBootstrap; |
21
|
|
|
use OCP\AppFramework\Bootstrap\IRegistrationContext; |
22
|
|
|
use OCP\Util; |
23
|
|
|
|
24
|
|
|
class Application extends App implements IBootstrap |
25
|
|
|
{ |
26
|
|
|
public const APP_ID = 'audioplayer'; |
27
|
|
|
|
28
|
|
|
public function __construct(array $urlParams = []) |
29
|
|
|
{ |
30
|
|
|
parent::__construct(self::APP_ID, $urlParams); |
31
|
|
|
} |
32
|
|
|
|
33
|
|
|
public function register(IRegistrationContext $context): void |
34
|
|
|
{ |
35
|
|
|
$context->registerDashboardWidget(Widget::class); |
36
|
|
|
$context->registerEventListener(BeforeTemplateRenderedEvent::class, LoadAdditionalScripts::class); |
37
|
|
|
$context->registerSearchProvider(Provider::class); |
38
|
|
|
$this->registerFileHooks(); |
39
|
|
|
$this->registerUserHooks(); |
40
|
|
|
} |
41
|
|
|
|
42
|
|
|
protected function registerFileHooks() |
43
|
|
|
{ |
44
|
|
|
Util::connectHook( |
|
|
|
|
45
|
|
|
'OC_Filesystem', 'delete', '\OCA\audioplayer\Hooks\FileHooks', 'deleteTrack' |
46
|
|
|
); |
47
|
|
|
} |
48
|
|
|
|
49
|
|
|
protected function registerUserHooks() |
50
|
|
|
{ |
51
|
|
|
Util::connectHook( |
|
|
|
|
52
|
|
|
'OC_User', 'post_deleteUser', '\OCA\audioplayer\Hooks\UserHooks', 'deleteUser' |
53
|
|
|
); |
54
|
|
|
} |
55
|
|
|
|
56
|
|
|
public function boot(IBootContext $context): void |
57
|
|
|
{ |
58
|
|
|
} |
59
|
|
|
|
60
|
|
|
} |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths