PluginProbe
WPIDE – File Manager & Code Editor / 3.4.7
WPIDE – File Manager & Code Editor v3.4.7
3.5.8 3.5.7 2.0.14 2.0.15 2.0.16 2.0.2 2.0.4 2.0.5 2.0.6 2.0.7 2.0.8 2.0.9 2.1 2.2 2.3 2.3.1 2.3.2 2.4.0 2.5 2.6 3.0 3.1 3.2 3.3 3.4 All 54 releases
wpide / _services.php

_services.php in WPIDE – File Manager & Code Editor 3.4.7, at _services.php

95 lines 3.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 defined( 'ABSPATH' ) || exit;
3
4 use WPIDE\App\Services\Storage\LocalFileSystem;
5 use WPIDE\App\Classes\Freemius;
6
7 use const WPIDE\Constants\DIR;
8 use const WPIDE\Constants\SLUG;
9 use const WPIDE\Constants\TMP_DIR;
10 use const WPIDE\Constants\WP_PATH;
11
12 return [
13 'WPIDE\App\Services\Logger\LoggerInterface' => [
14 'handler' => '\WPIDE\App\Services\Logger\Adapters\MonoLogger',
15 'config' => [
16 'monolog_handlers' => [
17 function () {
18 return new \Monolog\Handler\StreamHandler(
19 ini_get('error_log'),
20 \Monolog\Logger::DEBUG
21 );
22 },
23 ],
24 ],
25 ],
26 'WPIDE\App\Services\Cors\Cors' => [
27 'handler' => '\WPIDE\App\Services\Cors\Cors',
28 'config' => [
29 'enabled' => defined('WP_DEBUG') && WP_DEBUG,
30 ],
31 ],
32 'WPIDE\App\Services\Tmpfs\TmpfsInterface' => [
33 'handler' => '\WPIDE\App\Services\Tmpfs\Adapters\Tmpfs',
34 'config' => [
35 'path' => TMP_DIR,
36 'gc_probability_perc' => 10,
37 'gc_older_than' => 60 * 60 * 24 * 2, // 2 days
38 ],
39 ],
40 'WPIDE\App\Services\Security\Security' => [
41 'handler' => '\WPIDE\App\Services\Security\Security',
42 'config' => [
43 'ip_allowlist' => [],
44 'ip_denylist' => []
45 ],
46 ],
47 'WPIDE\App\Services\View\ViewInterface' => [
48 'handler' => '\WPIDE\App\Services\View\Adapters\Vuejs',
49 'config' => [],
50 ],
51 'WPIDE\App\Services\Storage\Filesystem' => [
52 'handler' => '\WPIDE\App\Services\Storage\Filesystem',
53 'config' => LocalFileSystem::getConfig(),
54 ],
55 'WPIDE\App\Services\Database\Database' => [
56 'handler' => Freemius::sdk()->can_use_premium_code__premium_only() ? '\WPIDE\App\Services\Database\Database' : null,
57 'config' => [],
58 ],
59 'WPIDE\App\Services\ConfigManager\ConfigManager' => [
60 'handler' => Freemius::sdk()->can_use_premium_code__premium_only() ? '\WPIDE\App\Services\ConfigManager\ConfigManager' : null,
61 'config' => [],
62 ],
63 'WPIDE\App\Services\Cache\Cache' => [
64 'handler' => '\WPIDE\App\Services\Cache\Cache',
65 'config' => [
66 'group' => SLUG
67 ],
68 ],
69 'WPIDE\App\Services\Transient\Transient' => [
70 'handler' => '\WPIDE\App\Services\Transient\Transient',
71 'config' => [
72 'prefix' => SLUG.'_'
73 ],
74 ],
75 'WPIDE\App\Services\Archiver\ArchiverInterface' => [
76 'handler' => '\WPIDE\App\Services\Archiver\Adapters\ZipArchiver',
77 'config' => [],
78 ],
79 'WPIDE\App\Services\Auth\AuthInterface' => [
80 'handler' => '\WPIDE\App\Services\Auth\Adapters\WPAuth',
81 'config' => [
82 'wp_dir' => WP_PATH,
83 'permissions' => ['read', 'write', 'upload', 'download', 'batchdownload', 'zip'],
84 'private_repos' => false,
85 ],
86 ],
87 'WPIDE\App\Services\Router\Router' => [
88 'handler' => '\WPIDE\App\Services\Router\Router',
89 'config' => [
90 'query_param' => 'req',
91 'routes_file' => DIR.'_routes.php',
92 ],
93 ],
94 ];
95