Passed
Pull Request — master (#5)
by Michael
02:29
created

getPaths()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 19
Code Lines 15

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 15
c 1
b 0
f 0
dl 0
loc 19
rs 9.7666
cc 1
nc 1
nop 0
1
<?php
2
3
/**
4
 * @return object
5
 */
6
7
$moduleDirName      = \basename(\dirname(__DIR__));
8
$moduleDirNameUpper = mb_strtoupper($moduleDirName);
9
10
return (object)[
11
    'name'          => mb_strtoupper($moduleDirName) . ' PathConfigurator',
12
    'paths'         => [
13
        'dirname'    => $moduleDirName,
14
        'admin'      => XOOPS_ROOT_PATH . '/modules/' . $moduleDirName . '/admin',
15
        'modPath'    => XOOPS_ROOT_PATH . '/modules/' . $moduleDirName,
16
        'modUrl'     => XOOPS_URL . '/modules/' . $moduleDirName,
17
        'uploadPath' => XOOPS_UPLOAD_PATH . '/' . $moduleDirName,
18
        'uploadUrl'  => XOOPS_UPLOAD_URL . '/' . $moduleDirName,
19
    ],
20
    'uploadFolders' => [
21
        XOOPS_UPLOAD_PATH . '/' . $moduleDirName,
22
        XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/category',
23
        XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/screenshots',
24
        //XOOPS_UPLOAD_PATH . '/flags'
25
    ],
26
];
27
28