helpers.php ➔ theme_asset()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 2
eloc 3
nc 2
nop 2
dl 0
loc 6
rs 9.4285
c 0
b 0
f 0
1
<?php
2
3
if (! function_exists('theme_asset')) {
4
    /**
5
     * Get theme public path.
6
     *
7
     * @param string $path
8
     * @param bool|null $secure
9
     * @return string
10
     */
11
    function theme_asset($path = '', $secure = null)
12
    {
13
        $path = $path ? DIRECTORY_SEPARATOR . $path : $path;
14
15
        return asset('themes' . DIRECTORY_SEPARATOR . config('themes.frontend', 'default') . $path, $secure);
16
    }
17
}
18